How does a user get the current date, time in UNIX?

Answer Posted / niranjan

command : $ date

date having different options according to reqirement like MMDDYY or day of the week,month name,weekday plenty off:)

$date %c gives current time with date month year

Is This Answer Correct ?    4 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What does find command return in unix?

590


What are bash commands?

588


What is awk good for?

578


When i run a programm of orphan process. Instead of getting child's parent (ppid)=1 ..i get 1400 and it varies as per system. How can i findthe right soluion??? My pgm: #include # include int main() { int pid; pid=fork(); if(pid < 0) {exit(-1);} else if(pid==0) { printf("Child Process is Sleeping ..."); sleep(10); printf("Orphan Child's Parent ID : %u ",getppid()); } else { printf("Parent Process Completed ... %u ",getpid()); exit(0); } return 0; } Output:

1756


Is command prompt unix?

575






What is the size of time_t?

640


What is the command to find maximum memory taking process on the server?

665


Which unix command to make a new directory?

586


What command will change your prompt to myprompt?

696


What does this command do? Cat food 1 > kitty

974


Which command is used to find whether the system is 32 bit or 64 bit?

627


Write a command that will find all text files in a directory such that it does not contain the word "amazing" in any form (that is, it must include the words amazing, amazing, or amazing)?

949


Enlist some filename manipulation commands in unix.

544


What is pipe command in unix?

664


Differentiate cmp command from diff command.

584