#include <iostream> // cin and cout (main funct for that lib)
#include "std_lib_facilities.h" // libs like cmath and algorithem
#define new '\n'
usingnamespace std;
double M,Y,D,MN,H,S,X,Z; //M = months Y = years D = days MN = minutes H = hours S = seconds X = JDN Z= JDN and ToD
// JDN = Julian date number ToD = Time of day... the variable Z is the jdn given the time of day
int main()
{
cout << "Age calc" << new;
cout << new;
cout << "The day You were born" << new;
cout << new;
cin >> D;
cout << "The Month You were born" << new;
cin >> M;
cout << "The Year You were born" << new;
cin >> Y;
out << "The Hour You were born" << new;
cout << new;
cin >> D;
cout << "The Minute You were born" << new;
cin >> M;
cout << "The Second You were born" << new;
cin >> Y;
cout << new;
cout << new;
x = (1461 × (Y + 4800 + (M - 14)/12))/4 +(367 × (M - 2 - 12 × ((M - 14)/12)))/12 - (3 × ((Y + 4900 + (M - 14)/12)/100))/4 + D - 32075
Z = X + ((H-12)/24) + (MN/1440) + (S/86400)
cout << Z << new;
system ("PAUSE");
return 0;
}
and please don't complain about me declaring a already key word...
Why shouldn't we complain about that? You should decidedly not be overwriting the name of an operator for a constant. As Bazzy noted, use endl instead, which appends a newline and flushes.
is endl a key word???
and how would i replace x with with a mathmatical operator. X is my variable. Doesn't the operator * multiply things???
Edit... Oh i see. you mean the formula...
yeah i copied and pasted that...