Calculate date and time from UNIX time

I need to calculate the date and time from UNIX time. And i need to do this without any extra libraries or includes. Just plain arithmetic code.
Topic archived. No new replies allowed.