My son is a senior and he needs to pass his C++ programming class to graduate in June. The quarter ends next week and he has to do 5 assignments and turn them in to have a shot at not failing the 3rd quarter.
I need a SIMPLE C++ compiler for Mac that does not expect much in the way of actual understanding of what you are doing.
Assignments read:
1. Write a program to average a number of test scores. Input the number fo test scores you would like to be averaged. Then inside a for loop input each score.
2. Write a program in which the computer generates a random number between 1 and 100. You have unlimited guesses to guess the correct number. Keep track of how many times the user makes a guess. The program will make a statement as to wether the guess is too high or too low and prompt the user to guess again. When the guess is right the program displays the number of guesses it took.
You will need to use: #include <stdlib.h> and #include<time.h> these will be needed to generate a random number.
strand (time(0)); //will seed the random number generator
Random Number = 1 + rand()%100; //will generate a random number between 1 and 100
I am not looking for someone to give me the answers - I just need a cheap or free compiler that will work in mac so he can work on this at home.
THANK YOU for any help you can give me.
I need a SIMPLE C++ compiler for Mac that does not expect much in the way of actual understanding of what you are doing.
Assignments read:
1. Write a program to average a number of test scores. Input the number fo test scores you would like to be averaged. Then inside a for loop input each score.
2. Write a program in which the computer generates a random number between 1 and 100. You have unlimited guesses to guess the correct number. Keep track of how many times the user makes a guess. The program will make a statement as to wether the guess is too high or too low and prompt the user to guess again. When the guess is right the program displays the number of guesses it took.
You will need to use: #include <stdlib.h> and #include<time.h> these will be needed to generate a random number.
strand (time(0)); //will seed the random number generator
Random Number = 1 + rand()%100; //will generate a random number between 1 and 100
I am not looking for someone to give me the answers - I just need a cheap or free compiler that will work in mac so he can work on this at home.
THANK YOU for any help you can give me.