Display the time of the system and display the right time
of the other country
Answer / ln007
Program to read the current date and time
#include<time.h>
main()
{
struct tm *k;
unsigned long int t;
int h,m,s;
int dd,mm,yy;
t = time(0);
k = localtime(&t);
h = k->tm_hour;
m = k->tm_min;
s = k->tm_sec;
dd = k->tm_mday;
mm = k->tm_mon+1;
yy = k->tm_year+1900;
printf("Time : %d : %d : %d\n",h,m,s);
printf("Date : %d : %d : %d\n",dd,mm,yy);
}
| Is This Answer Correct ? | 0 Yes | 1 No |
What are segment and offset addresses?
main() { if (!(1&&0)) { printf("OK I am done."); } else { printf("OK I am gone."); } } a. OK I am done b. OK I am gone c. compile error d. none of the above
C statement to copy a string without using loop and library function..
‎#define good bad main() { int good=1; int bad=0; printf ("good is:%d",good); }
can you use proc sql to manpulate a data set or would u prefer to use proc report ? if so why ? make up an example and explain in detail
main() { int a[10]; printf("%d",*a+1-*a+3); }
How to palindrom string in c language?
program to find the roots of a quadratic equation
14 Answers College School Exams Tests, Engineering, HP, IIIT, Infosys, Rajiv Gandhi University of Knowledge Technologies RGUKT, SSC,
Is the following code legal? struct a { int x; struct a b; }
what is oop?
print numbers till we want without using loops or condition statements like specifically(for,do while, while swiches, if etc)!
main() { int c = 5; printf("%d", main||c); } a. 1 b. 5 c. 0 d. none of the above