Game programming 1, week 1
|
Hello world! Last week (the week of november the 10th) the first programming course began but since this is my first blog post a short introduction may be needed. My name is Ludvig Normelli and I’m a game design and programming student at Uppsala university campus gotland. I have never blogged before so this is a new experience for me. The idea is that this blog will be a place which feature my thoughts about school projects or just school work in general. That’ll be enough, it’s time to get back to what I did last week. Programming is something new to me so there was a lot to take in during this first week. But I feel that I understood almost everything and I finished the exercises with relative ease. During the first week we talked about: We got some exercises to do during the week. The following is an example of these exercises and under that you can see my solution.
Program 18 My solution:
#include
int main(int argc, char* argv[])
{
int A = 0;
std::cout <> A;
for (; A > -1; A--)
{
std::cout << A << " bottles of juice on the wall, one fell down" << std::endl;
if (A == 0)
{
std::cout << "No bottles left on the wall" << std::endl;
}
}
std::cin.ignore(1024, 'n');
std::cin.get();
return 0;
}
Thanks for reading! // Ludvig
|