0% found this document useful (0 votes)
8 views4 pages

ICT Lab Project Fall 2024

The document outlines a group project for a C++ programming course, where students must develop a Number Guessing Game with dynamic difficulty levels and specific features. The project requires students to avoid using arrays and object-oriented programming, and includes detailed instructions for submission, game rules, scoring, and deliverables. Students are expected to apply programming concepts, problem-solving skills, and file handling while documenting their project process and outcomes.

Uploaded by

johnporj8
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
8 views4 pages

ICT Lab Project Fall 2024

The document outlines a group project for a C++ programming course, where students must develop a Number Guessing Game with dynamic difficulty levels and specific features. The project requires students to avoid using arrays and object-oriented programming, and includes detailed instructions for submission, game rules, scoring, and deliverables. Students are expected to apply programming concepts, problem-solving skills, and file handling while documenting their project process and outcomes.

Uploaded by

johnporj8
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

Complex Engineering Activity

Course Code and Title: CL1009 Applications of ICT Lab


Semester: 1st
Instructor: Aroosa Umair, Muiz Malik, Haniya Waheed
Total Marks: 30
Deadline: 8th December 2024

CLOs and PLOs for Complex Engineering Activity

CLOs Taxonomy PLO


Description
Levels Levels

LLO3 Lab Apply the knowledge of the subject in the lab C3 4


environment

LLO4 Lab Build a product or system meeting the requirements. P5 3

Instructions
 You must do this project in a group of 2 students.
 Use only those concepts that are covered in your course.
 Avoid using arrays and object-oriented programming (OOP).
 Submit a hardcopy(print) of your project report (1 report for each group) at the time of evaluation.
 Make a folder named your Roll Nos and paste the following documents into it:
o .cpp file
o Text file containing complete code of your
o Output text file (score.txt)
o Project Report
And submit it to Google Classroom.

Problem Statement
Develop a C++ program that implements a challenging Number Guessing Game with
dynamic difficulty. The program allows the player to guess a randomly generated number within a
specified range, provides detailed feedback on how close the guess is, and includes multiple difficulty
levels and a hint feature. The program should avoid using arrays and object-oriented programming
(OOP).

Game Overview:
In this advanced version of the Number Guessing Game, the program randomly selects a number within a
dynamically set range, based on difficulty level. The player receives feedback on each guess, with hints
available to help narrow down the correct answer. The objective is for the player to guess the number in as
few attempts as possible.

Game Rules and Conditions:

Page 1 of 4
1. Setup:
 The player selects a difficulty level (Easy, Medium, Hard), which affects the number
range and allowed attempts:
 Easy: Range 1-50, 12 attempts
 Medium: Range 1-100, 10 attempts
 Hard: Range 1-200, 8 attempts
 The program generates a random target number within the selected range using rand().
2. Hint System:
 The player has the option to request a hint, which provides an additional clue based
on their previous guess:
 Hints reveal whether the target number is odd/even or if it lies in the upper/lower
half of the range.
 Each hint request deducts one attempt from the total allowed attempts.

3. Feedback on Guesses:
 After each guess, the program calculates the difference between the guessed number
and the target, providing feedback based on this difference:
 Exact Match (0): "Correct! You’ve guessed the number."
 Very Far (difference > 40): "Way off."
 Far (difference between 20 and 40): "Still quite far."
 Close (difference between 10 and 20): "You're getting close!"
 Very Close (difference < 10): "Almost there!"
 If the guess is incorrect, the program also indicates whether the target is higher or
lower.

4. Winning and Losing Conditions:


 If the player guesses the correct number within the allowed attempts, the program
congratulates the player.
 If the player uses all attempts without guessing correctly, the program reveals the
target number and displays a game-over message.

5. Scoring System:
 Players are scored based on attempts remaining:
 Bonus for Remaining Attempts: Each unused attempt adds 10 points to the
final score.
 Hint Penalty: Each hint request deducts 5 points from the total score.
 Display the player’s final score at the end of the game.

6. Input Validation:
 Ensure that guesses fall within the selected range.
 If the player’s guess is out of range, prompt them to enter a valid number.

Program Features and Functionalities:

 Random Number Generation:


o Generate a random target number within the range selected by the difficulty level,
ensuring variability for each new game.
Page 2 of 4
 Dynamic Range and Feedback Messages:
o Display appropriate messages based on the player’s guess and difficulty level.
 Hint System:
o Deduct an attempt each time a player requests a hint, and provides additional clues
about the target.
 Scoring and Display:
o Calculate and display the score based on attempts used and hints requested and
announce the final score at game completion.
 File handling:
o Display the player details, game difficulty type, complete score, and result in a text
file score.txt

Objectives
 Apply basic concepts of Programming
 Develop Problem-Solving Skills
 Gain Experience with Dynamic User Interaction
 Implement File Handling
 Strengthen Algorithmic Thinking
 Understand Input Validation and Error Handling
 Explore Modular Design
 Experience Project Planning and Documentation

Deliverables

1. Identify Possible Solutions:


 Outline methods for managing game logic without arrays, such as handling hints and
scores with individual variables.

2. Solution Comparison:
 Compare methods based on ease of implementation and code clarity, justifying the
choice of approach.

3. Design and Implementation:


 Apply the selected approach to implement each feature, including feedback messages,
hints, and scoring.

4. Testing and Verification:


 Test each component with various inputs to ensure feedback, hints, and scoring are
accurate. Suggest possible improvements.
5. Limitations and Extensions:
 Discuss the current design’s limitations (e.g., no arrays or classes) and suggest
extensions, like adding more levels or multiplayer mode.

6. Management Plan:
Page 3 of 4
 Prepare a plan to complete the project successfully, including a flowchart with
program flow, input requirements, and output details.
7. Implementation Schedule:
 Outline a schedule for each part of the game, such as difficulty setup, random number
generation, feedback, and scoring.
8. Team Roles:
 If working in a team, describe each member’s role and tasks they completed.
9. Project Report:
 Create a detailed report summarizing the game’s design, testing outcomes, and key
insights.

Page 4 of 4

You might also like