I want to create a program that will calculate the day easter will be on. The user will type in a year and then the program should calculate the day easter will be on. I'm having trouble understanding the if/else and how i can use that with the code
// EasterProject
#include<iostream>
using namespace std;
int main()
{
int intyear, int intEasterDate, int intEasterMonth;
int a, b, c, d, e, f, g, h, i, j, k, m, p;
cout<< "What's the year? \n";
cin>> intyear;
Cout<<"Easter Month is \n";
if (intyear<0001||intyear>5000)
{cout<<"This calculator cannot serve you\n"
return -1;}
a=intyear%19;
b=intyear/100;
c=intyear%100;
d=b/4;
e=b%4;
f=(b+8)/25;
g=(b-f+1)/3;
h=((19*a)+b-d-g+15)%30;
i=c/4;
j=c%4;
k=(32+(2*e)+(2*i)-h-j)%7
m=(a+(11*h)+(22*k))/451
intEasterMonth=(h+k-(7*m)+114)/31
p=(h+k-(7*m)+114)%31
intEasterDate=p+1;
return 0;
}