Guyz i need an API for finding diff in time in minutes and days as fast as possible . if anybody has it and can provide me i wud be greatfull
Century handling is not important can do without it thanx
There is no standard function for that -- you will have to write your own. You could have written it yourself in the time that it took for me to post this response (5 hours).
Ya i have well i needed it a bit urgently so was expecting some one to share a bit of code it cud save a lot of my time ...but still if anybody got any efficient bit of function i wud still appreciate ... @ first i thought it to be easy but slowly got a lot of corner cases to handle
how about you take a look at the basics of calendar time functions in the time.h library, take a stab at it yourself, and then come back and ask specific questions.
because people here will generally NOT do your work for you. as you already found out in your earlier misguided attempt to plagiarize java code.
Look dude!!! first of all i wasnt palgiarizing i newer said it was my code and i dont need to work for me just
U better learn wt plagiarizing means and i obviously thought of not spending time on something that basic and i needed it urgently so thought somebody cud share it.. SO GET A LIFE DUDE
man, are you STILL using chatspeak?
have you considered just cutting your losses now, and creating a new account?
Its been 8 hours now and you still have not started writing the code yet! All you have to do is get the two date/times as time_t object, subtract them. The result is the difference in seconds. From that you can easily convert to minutes, hours, days, years, decades or whatever you want.
To get the time_t object, first populate a struct tm structure with the date/time and call mktime(), which returns time_t.
The whole thing might has taken you an hour or so to complete and test. Instead, you have so far wasted 8 hours trying to get someone else to do it for you. Not very efficient use of your time.
well, as he said, it's too basic for him to spend his time on, and its something he needs urgently.