Problems
Write programs for the following problems
//Sample skeleton program
using namespace std;
int main()
{
int r, g, b;
for(int i = 0; i < 256; i++)
{
r = 0;
g = 0;
b = i;
}
return 0;
}
//Sample skeleton program
using namespace std;
#define PI 3.14159265358979323846
int main()
{
int r, g, b;
double phaseShift = PI/3;
for(int i = 0; i < 360 * 3; i++)
{
r = 256/2 * sin(i * PI / 180 + phaseShift) + 256/2;
g = 0;
b = 256/2 * sin(i * PI / 180) + 256/2;
}
return 0;
}
What to submit
Submit both C++ program and HTML output file to Canvas by the midnight of the due day.