- Trending Categories
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
Physics
Chemistry
Biology
Mathematics
English
Economics
Psychology
Social Studies
Fashion Studies
Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Karthikeya Boyini has Published 2383 Articles
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
40 Views
The ftp_pwd() function returns the present working directory i.e. the current directory.Syntaxftw_pwd(con)Parameterscon − The FTP connectionReturnThe ftp_pwd() function returns TRUE on success or FALSE on failure.ExampleThe following is an example −
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
388 Views
The method java.io.File.isFile() is used to check whether the given file is an existing file in Java. Similarly, the method java.io.File.isDirectory() is used to check whether the given file is a directory in Java. Both of these methods require no parameters.A program that demonstrates this is given as follows −Examplepublic ... Read More
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
209 Views
To work with SimpleDateFormat class in Java, import the following package.import java.text.SimpleDateFormat;Now, set the format with SimpleDateFormat(“s”) to display seconds in one-digit.Format f = new SimpleDateFormat(”s”);Now, get the seconds in a string.String strSeconds = f.format(new Date());The following is an example −Example Live Demoimport java.text.Format; import java.text.SimpleDateFormat; import java.util.Date; import java.util.Calendar; public ... Read More
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
6K+ Views
The method java.io.File.exists() is used to check whether a file or a directory exists or not. This method returns true if the file or directory specified by the abstract path name exists and false if it does not exist.A program that demonstrates this is given as follows −Exampleimport java.io.File; public ... Read More
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
58 Views
The lower() method of NavigableSet returns the greatest element strictly less than the given element i.e. 35 here −lower(35);The following is an example to implement the lower() method in Java −Example Live Demoimport java.util.NavigableSet; import java.util.TreeSet; public class Demo { public static void main(String[] args) { ... Read More
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
2K+ Views
The method java.io.File.canRead() is used to check if a file or directory is readable in Java. This method returns true if the file specified by the abstract path name can be read by an application and false otherwise.A program that demonstrates this is given as follows −Example Live Demoimport java.io.File; public ... Read More
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
186 Views
Let us set a radix here as.// radix int r = 32;Include the radix here as a BigInteger constructor.BigInteger one = new BigInteger("vv", r);Now get its string representation −String strResult = one.toString(radix);The following is an example −Example Live Demoimport java.math.*; public class Demo { public static void main(String[] ... Read More
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
41 Views
The ftp_raw() function is used to sends raw command to the FTP server.Syntaxftp_raw(con, command)Parameterscon − The FTP connectioncommand − The command to executeReturnThe ftp_raw() function returns the server's response as an array of strings.ExampleThe following is an example −
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
241 Views
The name of the specified file or directory can be obtained using the method java.io.File.getName(). The getName() returns the name of the file or the directory and it requires no parameters.A program that demonstrates this is given as follows −Example Live Demoimport java.io.File; public class Demo { public static void ... Read More
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
401 Views
First, use the getenv() method to get the environment variables −System.out.println("PATH = " + System.getenv("PATH"));Now, get the key and value. Loop through to get the list of environment variables −Map e = System.getenv(); for (Iterator i = e.entrySet().iterator(); i.hasNext();) { Map.Entry mapEntry = (Map.Entry) i.next(); ... Read More