Find Jobs
Hire Freelancers

create a typing game in C++. (C++ language only) (should be working in eclipse CDT)

$10-30 USD

Ολοκληρώθηκε
Αναρτήθηκε πάνω από 7 χρόνια πριν

$10-30 USD

Πληρωμή κατά την παράδοση
This is to implement a simple typing lesson game. Computer will generate a random string of 7 characters and you need to reproduce it within 7 seconds. You will lose points significantly if you fail to produce the same string within the set time interval. You have 1000 points in the beginning of the game. Given 7 randomly generated letters being mixed with lower and upper cases, you need to type them correctly within 7 seconds (7000 msec). You will get 500 points every time you produce the matching string within the interval. You will loose an amount of delayed time in millisecond, e.g., your typing ended in 7350 msec, so you would loose 350 points. If you misspell, you will be penalized by the total offset of mistaken letters. You will loose this offset from your points. The offset is computed by accumulating the absolute distance between two characters in the same position, one from the generated string and another from the input. For instance, the offset of "Game" and "Mag" is 81. The shorter string is padded with space(s). Therefore, |G - M| = 6, |a - a| = 0, |m - g| = 6, |e - (space)| = 69. Use ASCII table ([login to view URL]) to see the assigned number to each alphabet under "char" and "html". If you misspell and overtime, you will be penalized the double score of the offset, plus delayed amount of time. The game ends if you reach score 5000 or 0. With 20% of chance of each character generation, a resulting string may contain wild letters, [0-9] and [%-&], which respectively indicate any number letter and any symbol letter, that means that either of the two wild letters is chosen with the probability of 0.2 when generating a random letter. Symbol excludes digits and upper/lowercase letters. Typing error is treated as an offset from '0' and '*' respectively. For instance, the offset of Twv[0-9]JG[%-&] and TwvxJG2 is 80. There were a few ways to approximate elapsed time. The new C++ 2011 standard has a good way to do it by including <chrono> library. See the item 17 of this post ([login to view URL]) to adapt into your logic. Furthermore, to activate C++ 2011 standard, you need to instruct g++ compiler with -std=c++11 option. Refer to this post #143 ([login to view URL]) to realize it. See the next sample game session: Your current points 1000, just type -> PEq[0-9]R[%-&][0-9]: PEq0R%0 4958 milliseconds, you made it within the interval of 7000... Your current points 1500, just type -> nELJSgd: nELJSgd 4297 milliseconds, you made it within the interval of 7000... Your current points 2000, just type -> gP[0-9][0-9]uCO: gP00uCO 5816 milliseconds, you made it within the interval of 7000... Your current points 2500, just type -> [0-9][0-9]nQp[0-9]m: 00nQp0m 6131 milliseconds, you made it within the interval of 7000... Your current points 3000, just type -> UIqIaBX: UIqIaBX 5861 milliseconds, you made it within the interval of 7000... Your current points 3500, just type -> [%-&]ErooJ[%-&]: %-&ErooJx 8966 milliseconds, you *failed* it within the interval of 7000... String offset is 381, your total penalty is 2728... Your current points 772, just type -> [%-&]pXwMFm: %pXmS2g 10698 milliseconds, you *failed* it within the interval of 7000... String offset is 42, your total penalty is 3782... Bye... Use isdigit() and isalnum() utility functions wisely. Finally, like the previous assignment, implement the specified task with your shortest possible coding.
Ταυτότητα εργασίας: 11597579

Σχετικά με την εργασία

7 προτάσεις
Απομακρυσμένη Εργασία
Ενεργός/ή 8 χρόνια πριν

Ψάχνεις τρόπο για να κερδίσεις μερικά χρήματα;

Πλεονεκτήματα πλειοδοσίας στο Freelancer

Καθόρισε τον προϋπολογισμό σου και το χρονοδιάγραμμα
Πληρώσου για τη δουλειά σου
Περίγραψε την πρόταση σου
Η εγγραφή και η πλειοδοσία σε εργασίες είναι δωρεάν
Βραβεύτηκε στον/στην:
Avatar Χρήστη
$15 USD σε 1 ημέρα
5,0 (2 αξιολογήσεις)
1,1
1,1
7 freelancers δίνουν μια μέση προσφορά $44 USD για αυτή τη δουλειά
Avatar Χρήστη
Hi. Contact me to discuss problem over chat. It would be great if you give me more information .
$25 USD σε 1 ημέρα
5,0 (2 αξιολογήσεις)
2,1
2,1
Avatar Χρήστη
I'm used to this kind of game (in C/C++) because I already worked with many similar university projects/works. Also, C/C++ are my favorite languages, and I'm well oriented at how to build, debug and optmize codes of these languages. But my bigger motivation to be awarded is because I want to do it. It's funny, well explained, and I know I'm completely capable of finishing it soon. Please let me know if there's any doubt about my bid or anything to discuss at all. Best Regards, Hygor.
$55 USD σε 3 ημέρες
0,0 (0 αξιολογήσεις)
0,0
0,0

Σχετικά με τον πελάτη

Σημαία της UNITED STATES
SUNNYSIDE, United States
5,0
6
Επαληθευμένη μέθοδος πληρωμής
Μέλος από Σεπ 14, 2016

Επαλήθευση Πελάτη

Ευχαριστούμε! Σου έχουμε στείλει ένα email με ένα σύνδεσμο για να διεκδικήσεις τη δωρεάν πίστωση σου.
Κάτι πήγε στραβά κατά την προσπάθεια αποστολής του email σου. Παρακαλούμε δοκίμασε ξανά.
Εγγεγραμμένοι Χρήστες Συνολικές Αναρτημένες Δουλειές
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Φόρτωση προεπισκόπησης
Δόθηκε πρόσβαση για Geolocation.
Η σύνδεση σου έχει λήξει και τώρα έχεις αποσυνδεθεί. Παρακαλούμε συνδέσου ξανά.