Build Student Information Tracker

CCBeginner
Practice Now

Introduction

In this challenge, a new school administrator needs to create a simple digital record system to capture and manage basic student information using fundamental C programming techniques learned in the lab. The program should be able to capture student details such as full name, age, grade level, and academic score, and display the information in a formatted output.


Skills Graph

%%%%{init: {'theme':'neutral'}}%%%% flowchart RL c(("C")) -.-> c/BasicsGroup(["Basics"]) c(("C")) -.-> c/UserInteractionGroup(["User Interaction"]) c/BasicsGroup -.-> c/variables("Variables") c/UserInteractionGroup -.-> c/user_input("User Input") c/UserInteractionGroup -.-> c/output("Output") subgraph Lab Skills c/variables -.-> lab-438353{{"Build Student Information Tracker"}} c/user_input -.-> lab-438353{{"Build Student Information Tracker"}} c/output -.-> lab-438353{{"Build Student Information Tracker"}} end

Build Student Information Tracker

As a new school administrator, you need to create a simple digital record system to capture and manage basic student information using fundamental C programming techniques learned in the lab.

Tasks

  • Open the C program named student_tracker.c in the ~/project directory
  • Implement input methods to collect student details
  • Display the collected student information with formatted output

Requirements

  • Use the file ~/project/student_tracker.c for your solution
  • Capture the following student details:
    • Full name (string, max 50 characters)
    • Age (integer)
    • Grade level (integer)
    • Academic score (float)
  • Use scanf() to input student information
  • Use printf() to display student information with proper formatting
  • Include necessary header files
  • Ensure the program compiles without warnings

Examples

gcc student_tracker.c -o student_tracker
./student_tracker

Example Input:

Enter student name: John Doe
Enter student age: 16
Enter grade level: 10
Enter academic score: 87.5

Example Output:

--- Student Information ---
Name: John Doe
Age: 16 years
Grade Level: 10
Academic Score: 87.50

Hints

  • Remember to use & when passing variables to scanf()
  • Use %[^\n] to read full names with spaces
  • Add a space before %c in scanf() to handle input buffer
  • Use format specifiers like %.2f for precise decimal display
โœจ Check Solution and Practice

Summary

In summary, the goal of this challenge is for the new school administrator to create a simple C program that can capture and manage basic student information, including full name, age, grade level, and academic score. The program should use fundamental C programming techniques to collect student details through input methods and display the information in a formatted output.