A command-line Notes Manager built with Python, Object-Oriented Programming, and JSON file storage.
The application allows users to add, view, search, update, and delete notes while keeping the data permanently stored in a JSON file.
- ➕ Add notes
- 👀 View all notes
- 🔍 Search notes
- ✏️ Update notes
- 🗑️ Delete notes
- 💾 Persistent JSON storage
- 🛡️ Input validation
- 🖥️ Menu-driven command-line interface
- Python 3
- Object-Oriented Programming
- JSON
- File Handling
osmodule- Lists
- Dictionaries
- Loops
- Functions
- String manipulation
- Exception Handling
python-notes-manager/
│
├── main.py
├── notes_manager.py
├── notes.json
└── README.md
The program stores each note as a dictionary containing a title and content.
Example:
{
"title": "Python",
"content": "Practice JSON and dictionaries"
}All notes are stored inside a list and saved permanently to notes.json.
==============================
📝 NOTES MANAGER
==============================
1. Add Note
2. View Notes
3. Search Notes
4. Update Note
5. Delete Note
6. Exit
Make sure Python 3 is installed.
Run:
python main.pyExample:
Enter note title: Python
Enter note content: Practice JSON and dictionaries
Note added successfully! ✅
Example:
===== YOUR NOTES =====
1. Python
Practice JSON and dictionaries
2. Gym
Chest workout
Users can search for a keyword in the title or content.
Example:
Enter keyword to search: python
===== NOTE FOUND =====
Title : Python
Content : Practice JSON and dictionaries
The search is case-insensitive, so Python, python, and PYTHON are treated the same.
Users can select a note by its number and update its title or content.
Example:
Enter note number to update: 1
Enter new title (Python): Python Practice
Enter new content (Practice JSON and dictionaries): Learn JSON and OOP
Note updated successfully! ✅
Users can delete a note by selecting its number.
Example:
Enter note number to delete: 2
Deleted: Gym ✅
Notes are permanently stored in notes.json.
Example:
[
{
"title": "Python",
"content": "Practice JSON and dictionaries"
},
{
"title": "DSA",
"content": "Practice arrays and strings"
}
]- Classes
- Objects
__init__()self- Methods
- Modules
- Functions
return- JSON
- File handling
os.path.exists()- Lists
- Dictionaries
- Nested data structures
append()pop()enumerate()len()input().strip().lower()inoperator- Dictionary value updates
forloopswhileloopsif/elif/elsetry/exceptValueError- Data persistence
The search feature checks both the title and content of every note.
Example:
Keyword: python
Title: Python Practice
Content: Learn JSON
The note will be found because the keyword exists in the title.
The program checks whether the selected note number is valid.
Invalid numbers or non-numeric input are handled without crashing the program.
Example:
Enter note number: abc
Please enter a valid number.
- Add note categories
- Add timestamps
- Add note IDs
- Add favorite notes
- Add archive functionality
- Add sorting
- Add multiple-line note content
- Add password protection
- Add search filters
- Add GUI interface
- Add database support
This project is designed for learning Python programming, Object-Oriented Programming, JSON persistence, searching, updating data, and command-line application development.
Ayushman Tiwari
GitHub: https://github.com/ayushman-ece
This project is part of my Python project practice focused on building real-world applications and strengthening Python programming fundamentals, Object-Oriented Programming, JSON file handling, data persistence, searching, updating, and data management.