But, for your learning purpose, here is how to define the getInt function.
int getInt()
{
int h;
printf("please choose a positive integer for the height of Mario's pyramid less then 24 \n");
scanf("%d",&h);
return h;
}
regards,
Raghav
This post has been edited by raghav.naganathan: 24 November 2012 - 01:56 AM

New Topic/Question
Reply




MultiQuote




|