Skip to content

Instantly share code, notes, and snippets.

@Deadairx
Created Nov 22, 2019
Embed
What would you like to do?
var secondsPerMin = 60;
var minsPerHour = 60;
var hoursPerDay = 24;
var daysPerWeek = 7
var weeksPerYEar = 52;
var secondsPerDay = secondsPerMin * minsPerHour * hoursPerDay;
document.write("<p>There are " + secondsPerDay + " seconds in a day</p>");
var yearsAlive = 29
var secondsAlive = secondsPerDay * daysPerWeek * weeksPerYEar * yearsAlive;
document.write("<p>I have been alive for " + secondsAlive + " seconds.</p>");
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment