Jumbled Word Program
$30-250 USD
Teslim sırasında ödenir
Complete incomplete code in C (not C++).
You will use 3 character arrays:
1. Jumbled word
2. Solution word
3. Guess word
• The jumbled word and the solution word will be read from an input file
• The user will be presented with the jumbled word
• The user will have 3 chances to guess the word
• If the user does not guess the word on the first guess, the first and last letters will be provided
• See the sample output below
• Be sure to greet the user and say goodbye to the user
• Be sure to change all 3 character arrays to all uppercase letters – use the toupper function from
ctype.h, one character at a time
• You will use %s to scanf the words and print the words
• You will use the strlen and strcmp functions from string.h
• You will use a do/while loop in the main function
Incomplete code:
// jumbled word game
#define _CRT_SECURE_NO_WARNINGS //for Visual Studio compiler
#pragma warning(disable:6031) //ignore scanf warnings
#include<stdio.h> //for printf, scanf, and fscanf
#include<ctype.h> //for toupper function
#include<string.h> //for strlen and strcmp functions
#define SIZE 25 //size of the character arrays is 25
void Instructions();
//Welcome the user and display the instructions on how to play the game.
void PlayOneGame(char jumbled[], char solution[]);
//input: solution word and scrambled word
//plays one round ot the game
void PlayAgain(char* againPtr);
//input: character (input/ouptput) parameter
//determines if the player would like to play again.
void UppercaseWord(char word[]);
//input: a character array with a null character (string)
//sets all of the characters in a word to uppercase letters
void WinOrLose(int win);
//input a 1 or a 0
//tells the user they won if the input is 1 and they lost if the input is 0
int main()
{
//declare character arrays here
//declare character and file pointer
//greet the user and disply the instructions
//connect to the input file
do {
//read 2 words fromthe file
//print the words to make sure they were read from the file correctly
//printf("\n jumbled is %s, correct is %s\n", jumbled, correct);
//change both jumbled and solution to uppercase letters
//play a round of the game -call the PlayOneGame function
//again?
} while //test
//say goodbye
//close the file pointer
//return Success (0)
}
void Instructions()
//Welcome the user and display the instructions on how to play the game.
{
//display a welcome message and game instructions
}
void PlayOneGame(char jumbled[], char solution[])
//input: solution word and scrambled word
//plays one round ot the game
{
//declare variables
//get the length of the solution word
//the user gets a maximum of 3 guesses
{
//display the number of letters and the jumbled word
//get the guess
//change the guess to uppercase letters
//use strcmp to see if guess and solution match
//stop the loop if they match (DO NOT USE A break statement to stop the loop)
//else the user did guess correctly
//display the first and lat letters
}
//disply the solution
//tell the user if they won or lost
}
void PlayAgain(char* againPtr)
//input: character (input/ouptput) parameter
//determines if the player would like to play again.
{
//again?
}
void UppercaseWord(char word[])
//input: a character array with a null character (string)
//sets all of the characters in a word to uppercase letters
{
//use strlen to get the length of the word
//use a loop to change all the letters of the word to upper case (toupper)
}
void WinOrLose(int win)
//input a 1 or a 0
//tells the user they won if the input is 1 and they lost if the input is 0
{
//let the user know if they won or lost the round
}
Proje NO: #29810468
Proje hakkında
Bu iş için 5 freelancer ortalamada $98 teklif veriyor
Hello, I read your job offer regarding the C programming and I'm ready to start right away. I am also flexible with whatever budget you have. Accuracy and client's satisfaction is the top priority. Awaiting your res Daha Fazla
❤️ ~ Hello ~ ❤️ As a professional who can realize your idea, I have rich experience in development for 15 years’ So far, I've always been striving only for customer satisfaction and have always provided Modern design Daha Fazla
Hello :D It can assist you in that aspect I am good at C and Java I can show you some demo if needed Pls text me, if you need an assistance Thank You
Hello! I can start work right now. I have over 7 years of experience in C++ developing. Because of COVID-19, I have started work in here from a few days ago. I am sure that you will be 100% satisfied. Please give me a Daha Fazla
Hello! Nice to meet you. I have read your proposal carefully and very interesting in your work. I have 10+ years experiences about C++/C#/Qt programming. Sure you will get good result. I will do my best for you and you Daha Fazla