Guessing Game

Budget $25 - $30 USD
Bids 36
Average Bid $13

This assignment requires the use of random numbers. You must include the <cstdlib> and <ctime> header files to allow access to rand() and srand(), respectively. These will be discussed in class. The program will implement a “guessing game.?? Ask the user for a number in the range of 1 through 100, inclusive. If the guess is larger than the random number you generated in the range of 1 through 100, inform the user that the guess was too high. If the guess is too low, say so, and when the guess matches the random number, say so! Also, tell the user how many guesses were required. What should you do if the user inputs an invalid guess? Suppose the user enters 0 or 200? You should allow only valid guesses. Therefore, keep asking for guesses until the user enters a number between 1 and 100, inclusive. Run the program 3 times and print the results (note: be sure to use some invalid guesses to test that part of your logic). Remember to print an error message (with the number) when an invalid guess is made. Code a function named, guess(), that will return a number in the range 1 to 100, inclusive. As discussed in class, the function, rand(), will return a random number in the range 0 to MAX, where MAX is a predefined constant (maybe 32767, or ??). Obviously, you must modify the random number to be in the range from 1 to 100, inclusive. Also, random numbers are generated using “seed?? values. Unless you change the seed each time the program is executed, the program will generate the same sequence of random numbers. This makes the game trivial once the user realizes that the random numbers are always the same! To avoid this problem, use srand() to “seed?? the random number generator. You use srand() only once in your program (not in a loop!) to change the seed value. This will cause the program to generate a different sequence of random numbers each time the program is executed! The exact function invocation is:

srand(time(NULL)); //use the system clock to generate a seed

Code the program to allow the user to play the game multiple times and display the average number of guesses at the end of the game. Suppose the user played the game 5 times and the number of guesses for each game was: 7, 4, 5, 5, and 8. The average number of guesses would be: 5.80. Also, allow the user to enter either an uppercase Y or a lowercase y to continue with another game!


## Deliverables

1) Complete and fully-functional working program(s) in executable form as well as complete source code of all work done.


2) Deliverables must be in ready-to-run condition, as follows (depending on the nature of the deliverables):
a) For web sites or other server-side deliverables intended to only ever exist in one place in the Buyer's environment--Deliverables must be installed by the Seller in ready-to-run condition in the Buyer's environment.
b) For all others including desktop software or software the buyer intends to distribute: A software installation package that will install the software in ready-to-run condition on the platform(s) specified in this bid request.
3) All deliverables will be considered "work made for hire" under U.S. Copyright law. Buyer will receive exclusive and complete copyrights to all work purchased. (No GPL, GNU, 3rd party components, etc. unless all copyright ramifications are explained AND AGREED TO by the buyer on the site per the coder's Seller Legal Agreement).

## Platform

Must be written in Microsoft Visual c++


Windows 2000

Post a Project Like This

This project was awarded to

letregrandecoder

Even though work proved to be a larger project then anticipated, the worker agreed to take on the extra work. She did a great job and addressed all my concearns and needs. Even though we went a bit over schedule, I would highly recomend this worker. Thanks for the good work.
About the Freelancer

Looking to make some money?

  • Set your budget and the time frame
  • Outline your proposal
  • Get paid for your work

Bids on this Project

  • lmxvw Profile Picture

    lmxvw

    Romania

    ## BIO . ## Area of Expertise Java core, enterprise, and web development XHTML/HTML/CSS/Javascript web UI

    PHP, Perl, ASP, and C Programming

  • saifullahbaig Profile Picture
  • starlightsoft Profile Picture

    starlightsoft

    United States

    ## BIO We are a group of 3 programmers with more than 12 years of experience in the field of programming. We have built many systems for different corporations including database projects/ network programs... etc... We love perfection, and customer satisfaction is our main and only concern. ## Area of Expertise We have used C/C++ under all platforms (Windows/Dos/Unix/Linux/ and even for mobile phones under Symbian). We are also experts of the Assembly language, Java (we have used many different Java technologies, including J2ME for mobile phones), and visual Basic.

    PHP, C Programming, Java, and JSP

  • paulabramsvw Profile Picture

    paulabramsvw

    Ottawa,  Canada

    ## BIO 0. CURRENT POSITION October 2008 - Present Software Developer Department of Justice, Canada - ASP.Net 1. EDUCATION Bachelor of Computer Science with honours Carleton University September 1999- May 2003 Ottawa, Canada - Major in software & computing - Minor in mathematics 2. TECHNICAL SKILLS PROGRAMMING Procedural - C (advanced) - Pascal (advanced) - Perl (intermediate) Object Oriented - Java (expert) - C++ (advanced) - Smalltalk (advanced) - ObjecTime/Rational Rose (intermediate) - UML (intermediate) - Visual Basic (novice) Functional/Logical - Scheme/LISP (advanced) - Prolog (intermediate) Database - SQL (advanced) - Oracle (intermediate) - Access (intermediate) Internet - HTML (intermediate) - CSS (intermediate) - JavaScript (intermediate) - CGI (novice) - JSP (novice) - XML (novice) Miscellaneous - Assembly/Machine-level (intermediate) - Linux/Unix scripting (intermediate) - Batch Files (advanced) SOFTWARE APPLICATION PROFICIENCIES Operating Systems - Windows 95/98/ME/NT/XP (expert) - Linux/UNIX (intermediate) - DOS (master) - Mac O/S, Solaris, FreeBSD (novice) Business Applications - Microsoft Office: Word, Excel, Access, Outlook, PowerPoint (advanced) - Corel Office: WordPerfect, Paradox, Quattro Pro, Presentations (advanced) - Lotus Notes (advanced) - ACCPAC (advanced) Graphic Design - Corel Draw (intermediate) - Adobe Photoshop (intermediate) - Macromedia Fireworks (intermediate) Web Design - Macromedia Dreamweaver (intermediate) - Microsoft FrontPage (intermediate) - Netscape Composer (intermediate) - IBM WebSphere (novice) Servers - IIS (intermediate) - Apache HTTP (novice) - WebSphere Application Server (novice) - Various third-party FTP (intermediate) Integrated Development Environments - MS Visual Studio (advanced) - Sun One Studio/ Forte (advanced) - Borland JBuilder (intermediate) - Borland Visual C++ (intermediate) 3. PERSONAL SKILLS - Superior analytical and cognitive ability - Superior written communication skills - Independent and extremely quick to learn - Am bilingual in French - Strong interpersonal skills - Easily meet deadlines - Hard-working with a professional attitude - Typing, 80 words per minute 4. EXPERIENCE February to March 2004 Software Developer Air Strategy LLC - Designed and implemented a euchre card game for use on handheld devices. This included the user interface for four separate devices as well as artificial intelligence for five levels of play. Programming was performed in C using the BREW software development kit from Qualcomm. December 2003 to Present Freelance Software Programmer Various Clients - Implement small to medium software solutions for international clients. Platforms of implementation include Linux and Windows operating systems using Java, C++ and C. December 2003 to Present Freelance Writer Various Clients - Perform article writing services, optionally search engine optimized. May 2003 to present OCD Productions Ottawa, Ontario Technical Support and Quality Control Consultant Responsibilities: - Promptly assess and correct technical problems as required in order to provide a reliable platform (Windows XP, Macromedia MX, pppoe internet connection) upon which website development can be reliably conducted. - Provide English language Editing and Proofreading services. December 16 2003 Volunteer Canada Ottawa, Ontario - Delivered Microsoft Office training workshop to Volunteer Canada employees. May-August 2002 City Living Ottawa, Ontario Housing Assistant - Responsible for processing and dispatching all maintenance requests for over 2000 housing units at sites throughout West Ottawa. - Assessed the validity and urgency of each request and dispatched labor based on analysis of available resources. - Demonstrated ability to multi-task in a fast-paced work environment. May-August 2001 City Living Ottawa, Ontario Arrears Clerk - Primary duties involved daily contact with tenants in rental arrears. - Secondary responsibilities included aiding housing officers with clerical, customer service and administrative duties. June-August 2000 City Living Ottawa, Ontario Archives Clerk - Responsible for implementation of an archiving project for former and current tenant files, which was finished in less than one third of estimated completion time. - Upon completion of above project, was assigned to assist with clerical and customer service duties related to daily dealings with current tenants and housing of new tenants. August 1995 - February 2000 McDonald?s Restaurants Ottawa, Ontario Manager - Led a team of employees to quickly deliver quality products to customers in a high-volume restaurant. - Side duties included accounting, employee scheduling, ordering and receiving product, and maintenance and repair of equipment. - Certified workplace health and safety representative. 5. ACHIEVEMENTS - Recipient of a 1000 dollar entrance scholarship from Carleton University. - In 1992, was selected as one of four high school students representing the Ottawa area to attend a two-week workshop at the Ontario Camp Leadership Centre at Bark Lake, Ontario. - Played lead saxophone in a high school band to win the gold medal at an international competition in New Orleans in 1993. - President of Gloucester High School chess club 1993-1994. - Operated a computer bulletin board system (BBS) in 1993-1995 which attracted over 700 members. - Obtained a score of 91% (50/55) on the Graduate Recruitment Test (GRT) and 86% (43/50) on the Written Communication Proficiency Test (WCPT) offered by the Public Service commission of Canada. - Member of the program for the intellectually gifted throughout high school. ## Area of Expertise TECHNICAL I have implemented software solutions using all of the following technologies: Java, C/C++, HTML, Perl, Scheme/LISP, Smalltalk, JavaScript, PHP, XML, CSS, CGI, Visual Basic, SQL, Oracle and others. I have implemented solutions on all Windows platforms and on various Linux/UNIX platforms. Some samples of previous work are available at my website, which is not available from this description as it contains my personal contact information. OTHER Superior English written communication skills. Writing samples are available online.

    PHP, Perl, ASP, and Adobe Flash

  • misterdiablo Profile Picture

    misterdiablo

    Romania

    ## BIO Name : Moisa Bogdan Country : Romania Age : 24 Studies : Automatics and Computers Science student ## Area of Expertise Linux C/C++ Java Asm

    PHP, ASP, C Programming, and Java

  • wahabsl Profile Picture

    wahabsl

    Cairo,  Egypt

    Areas Of Expertise: C, C++, MFC, API, Java, Java beans, applets, AWT, Swings, sockets, JDBC, JSP, Mozart Oz, prolog, clips, C under Linux, X window programming, Fortran, Pascal, SQL, PL SQL, HTML, Java script, ODBC, ADO, Visual Basic, 286 assembly, ActiveX, DirectX (direct Draw)), Oracle 8i, Linux, Matlab Resume: EDUCATION Bachelor of Science in Computer Science, Faculty of Computers and information Cairo University, graduated June 2001 Major : Computer Science Masters Thesis : Evolving Fuzzy Cellular Automata (Registered October 2002, Expected Finishing June 2004) Premasters Average Grade Thesis : Excellent : A Survey on Java Virtual Machine Implementation (Grade Excellent) Premasters coursework : Declarative programming, Complexity theory, Theory of computation, Genetic Algorithm and neural Networks, Security, Parallel Processing Graduation Average Grade Thesis : Excellent with honors (ranked 3rd) : Design and implementation of Cryptographic Algorithms (Grade Excellent 200/200) Undergraduate Coursework : Programming Language C, C++, Data Structure, File Structure, Operating System 1 & 2, Networks 1 & 2 & 3, Operations Research, Graphics 1 & 2, Image Processing, Software Engineering 1 & 2, Database 1 & 2, Math 1 & 2 & 3 , Statistics 1 & 2, Discrete Math, Physics, Digital logic design, Artificial intelligence, Computer Architecture, Natural Language Processing, Knowledge Base System, Security, Parallel Computing, Arabization, Concepts of programming languages, Assembly, Multimedia, Compilers, mathematical Logic . International General Certificate of Secondary Education (IGCSE), Misr Language School, Egypt, June 1997 (96.25 %) WORK EXPERIENCE Trainee, Giza Systems, August 2000 Received a training course in Oracle Data Base Administration Expanded my knowledge in PL SQL, SQL(DDL and DML) Consultant at Khalifa Computer Group Development of ActiveX components for multimedia applications using visual C++ Maintenance of the arabization system of its international software Design and Development of As-Siraj Al-Muneer program for recitation and interpretation of the Holy Quraan in Arabic, English, French, Dutch, and Indonesian. Design and Development of Tafseer Al Atfaal program for recitation and interpretation of the Holy Quraan in Arabic for Kids. Design and Development of Kamoos Tafseer Al Atfaal program. (Dictionary for Quraan words). Development of Noran Learns English 2 Website for Teaching English for Kids. Consultant at Binary Works Maintenance of the Show me E-Learning Solution. Assistant at the faculty of computers and information Cairo University Teaching digital design, arabization, expert systems, operating systems, graphics, compilers, assembly, artificial inelegance, data structures, discrete mathematics, and computers architecture. Judge and Contest Administrator in the Association of Computer Machinery (ACM Egypt National Programming contest held in the Faculty of computers and information Cairo University. October 2003 EXTRA CURRICULAR ACTIVITIES Member in the Cairo University Team; which participated in the Association of Computer Machinery (ACM ) North Africa, Arab and Middle East Regional Programming contest held in the American University in Cairo . November 2001 Our team of 3 accomplished the First place in the competition Member in the Cairo University Team; which participated in the Association of Computer Machinery (ACM World finals Programming contest held in the Hilton Hawaiian village. March 2002 Our team of 3 took an honorable mention Member in the Cairo University Team; which participated in the Association of Computer Machinery (ACM) Egyptian National Programming contest held in the AUC. October 2000 Our team of 3 accomplished the third place in the competition Member in the Cairo University Team; which participated in the Association of Computer Machinery (ACM ) North Africa, Arab and Middle East Regional Programming contest held in the Al Akhawayn University in Ifran Morocco . November 2000 Our team of 3 accomplished the fourth place in the competition Member in the Cairo University Team; which participated in the Association of Computer Machinery (ACM ) North Africa, Arab and Middle East Regional Programming contest held in the American University in Cairo . November 2002. Our team of 3 accomplished the fourth place in the competition PROJECTS Image Compression Package Via MFC An ActiveX component that convert bmp image files to JPEG Using Visual C++ Rendering 3D objects modeled in polygons and ray tracing via Windows API using Visual C++ Compiler. Database for a video library using Access. Designing an ISA card for controlling circuits. Design of Arabic text editor under Linux using C Chat Server program and Clients using java. Chat Server program and Clients using Mozart OZ. Manipulating objects using Open GL Operations research package (Linear Programming, Duality, Transportation and inventory control) Via C++ Linear programming applet and application via Java ACADEMIC WORK Library for string manipulation via C++ language Software simulation for multilevel queue CPU scheduling via C++ Programs for manipulating a file of student records via C++ Development of Software Engineering lifecycle of student record system English Natural language interface to database via prolog Arabic parser via prolog. HOBBIES Programming, reading programming books Solving mind games, surfing the net. Teaching advanced computer topics

  • brainstormingvw Profile Picture

    brainstormingvw

    Romania

    ## BIO Some of those projects have been made for certain clients, as a request) ## Area of Expertise Tools:Borland Delphi, Quick Reports, BDE, OOP, SQLTools:Borland Delphi, Quick Reports, BDE, OOP, SQL, C, C++, Visual C, Java

    PHP, C Programming, Visual Basic, and .NET

  • aditsu Profile Picture

    aditsu

    Hong Kong

    ## BIO Full name: Adrian Sandor Born in Romania, living in Hong Kong Studies: 1997-2001 – Bucharest University, School of Mathematics, Computer Science Department, graduated in June 2001 (B.Sc. degree in Computer Science) Contest prizes: 1998-1999 – 4th place in the world at the ACM ICPC finals, Eindhoven 1999, sponsored by IBM http://icpc.baylor.edu/past/icpc99/Finals/Tour/win/Win.html 1999-2000 – 15th place in the world at the ACM International Collegiate Programming Contest finals, Orlando 2000, sponsored by IBM http://icpc.baylor.edu/past/icpc2000/Finals/Standings.html http://icpc.baylor.edu/past/icpc2000/Finals/Tour/europe/team05.htm ## Area of Expertise C, C++, STL HTML, DHTML, client-side JavaScript ASP – InterDev – server-side VBScript/JavaScript XML, XSLT Delphi, C++Builder SQL – Access, SQL Server, MySQL

    PHP, ASP, C Programming, and Java

  • vw945703vw Profile Picture

    vw945703vw

    Bulgaria

    ## BIO For most of my conscious life I have been writing code for enjoyment at first and then later on for making a living as well. Although I spent most of my career working for big and small companies that owned me, there's still a considerable fraction of time when I was me own boss - and I regard that as the best time of my professional life, even though it never put me on Forbes Magazine lists:) I had the luck of having worked in companies that put considerable effort in advanced research and cutting-edge techs as well as in personnel qualification, so as a result I have varying degrees of expertise in many areas of contemporary IT and Computer science and some knowledge in virtually almost all of them (plus several certificates to hang on the wall and show off to my grandchildren at some point in the future). *Newsflash*: Java and mobile phones finally bored me nearly to death, so I just quit my job at one of the world's top 3 mobile and console games vendors and I'm back on track freelancing. ## Area of Expertise **Past work and high experience in the following areas**: Database Design, Database Development, Database Optimization Embedded Devices, Embedded Controllers, ulibc, WinCE Multithreading, Distributed Programming Driver Development, Linux Kernel Modules, VxD, DDK Digital Signal Processing, Pattern Recognition Win32 API, MAPI, TAPI, MFC, .NET Framework GUI Implementation, GNOME, KDE, QT, SDL, Allegro, Tk, GTK+ TCP/IP Networking, Serial Communication, Client-Server, Protocol Implementation Software Protection, Application Security, Data Encryption AI, Neural Networks, Expert Systems Interpreters, Custom Language Translators Text Processing Techniques, Regular Expressions General Optimizations, Compression Algorithms, Low-Level Programming ***Programming Languages***: * C/C++ * Perl * C# * PHP * SQL * Intel x86 Assembly * Unix shell scripting (bash, csh) * LISP ***OS expertise***: * GNU/Linux * Unix * Windows (NT, 95, 98, 2000, XP, 2003, CE, XP Embedded)

    PHP, Perl, ASP, and C Programming

  • hvw Profile Picture

    hvw

    Romania

    ## BIO We are a programmer team of 4 people who want to acumulate lots of experience. ## Area of Expertise C,C++,Delphi,Php,Mysql,Javascript

    PHP, C Programming, Windows Desktop, and Linux