Teen Mood & Habit Tracker

About the Project

The Teen Mood & Habit Tracker is a simple console-based application built in C to help teenagers track their mental well-being and daily habits. It allows users to log their mood, sleep, exercise, screen time, and write short journal entries — all stored locally without the need for the internet or a smartphone.

Inspiration

Teenagers today are under immense pressure — from school, social life, exams, to excessive screen exposure. Mental health can easily take a back seat. I wanted to create a tool that was:

  • Accessible (no need for internet or a phone)
  • Simple (lightweight and easy to use)
  • Private (stored offline)

Inspired by popular journaling and wellness apps, I chose to build something minimal using the C language — proving that even basic tools can support mental wellness.

How I Built It

The project was built using:

  • C Programming Language
  • File Handling (fopen, fprintf, fscanf) to store and read entries
  • Structs to organize daily data
  • Loops, conditionals, and string manipulation

Key Features:

  • Input mood rating (1–5)
  • Log healthy habits (sleep, exercise, screen time)
  • Optional journal entry
  • View weekly summary (average mood, good sleep days, etc.)

What I Learned

  • How to use struct and FILE operations in C
  • Handling string input securely with fgets and strcspn
  • How to parse and save structured text using delimiters
  • Importance of data formatting and user experience, even in a console app

Challenges Faced

  • Managing user input in the terminal without errors
  • Handling newline characters from scanf and fgets
  • Designing a readable file format for easy parsing
  • Keeping the interface simple but functional
  • Implementing a "summary" feature without using arrays or databases

Final Thoughts

Even a simple program written in C can make a meaningful impact. This project reminded me that small habits and daily reflections can help us better understand ourselves. I hope this tool can support someone — even just a little — in their journey to wellness.

Built With

Share this project:

Updates