Eve Wein

Greenhorn
+ Follow
since Nov 19, 2020
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
1
Given in last 30 days
1
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Eve Wein

John Matthews wrote:Never heard of that before, but looks interesting:
https://code2flow.com/

Presumably the free version doesn't meet your requirements, and if not, is paying $11 for (just) a month of the full version not an option?



I just need it for a presentation session, so I might just draw it using draw.io if no one else has it.
2 weeks ago
Hi, does anyone have a code 2 flow premium account? I need to generate a flowchart for a program of mine, to provide better visuals and clarity of thought during my presentation session.
2 weeks ago


I have written a program in C language. The program is designed for primary school students in Grades 1-2. Two integers are randomly selected, the numbers are either added or subtracted to form an equation, and the students are asked to solve the equation.

Code criteria:
a. Each round of the game consists of 10 questions that are not to be repeated. 10 marks for each question. Each round of games is required to be set anew and is not have the same questions as the previous rounds.


b. Only the addition and subtraction within 100 is allowed, the sum and difference of the two numbers should not exceed the range of 100, and is not to have a negative value.


c. For each question, players have 3 chances to enter their answers. 10 points are awarded for the first correct attempt, 7 points for the second attempt, 5 points for the third attempt, zero points if all 3 attempts failed. When an incorrect answer is entered, a message should appear prompting the student to re-enter the answer. Output the correct answer if all 3 attempts are used in the form "No, the answer is X".


d. At the end of the test, a message should appear prompting the player to choose "Show results", by entering the letter "S", "Play another round", by entering the letter "P", and "Quit", by entering the letter "Q". If the player entered "S" after one round of the game, output the player's score (marks/100). If the player chooses "Show results" after multiple rounds of the game, the output should include the player's highest score/%, lowest score/%, and the average score/% of all games played. If the player enters "Q", the program ends.


e. Include fault tolerance function, a simple menu interface, necessary notes. The program should also meet the requirements of modularization and structurization.

This is my code:



Code criteria not fulfilled:

d. At the end of the test, a message should appear prompting the player to choose "Show results", by entering the letter "S", "Play another round", by entering the letter "P", and "Quit", by entering the letter "Q". If the player entered "S" after one round of the game, output the player's score (marks/100). If the player chooses "Show results" after multiple rounds of the game, the output should include the player's highest score/%, lowest score/%, and the average score/% of all games played. If the player enters "Q", the program ends.

I know I might use a while loop to repeat the program but I don't know where to place it.

Besides, I have no idea how to output the scores as required in criteria d, I have only managed to set the program to include certain words of encouragement for a designated range of scores.

Lastly, how do I include a fault tolerance function? After inputting the letter "a" into one of the equations, the program just ends. I need a message to prompt the user to input a number.

Any help would be greatly appreciated.
2 weeks ago