r/learnpython • • 8h ago

Help needed for schools python learning

so a little of context i have computer science as a subject in grade 12 , and in it i have to study python , sql , stack and python connectivity with sql . i have managed to study sql but im struggling with python all i know is print("hello world") , i dont know if this is the right place to post this but help will be really appreciated . also i cant give it much time sadly coz i have subjects like physics chem and maths hanging in my neck . max i can give is 45 mins a day and i have to do it in under a month .

these are all the topics i need to learn

  • Basics: Tokens, keywords, identifiers, literals, variables, data types, operators, and type conversion.
  • Control Flow: Conditional statements (if, elif, else) and loops (for, while, break, continue).
  • Strings: Indexing, slicing, traversal, and built-in string methods.
  • Lists, Tuples, and Dictionaries: Creation, indexing, slicing, mutability vs. immutability, traversal, and built-in functions/methods.
  • Standard Modules: Importing and using math, random, and statistics.
  1. Functions
  • Types of Functions: Built-in functions, functions defined in modules, and user-defined functions (def).
  • Parameters & Arguments: Positional arguments, default parameters, and keyword (named) arguments.
  • Return Values: Returning single or multiple values (return statement) vs. void functions.
  • Scope of Variables: Global scope vs. local scope and the global keyword.
  1. Exception Handling
  • Error Types: Syntax errors, runtime errors (exceptions), and logical errors.
  • Built-in Exceptions: ZeroDivisionError, TypeError, ValueError, IndexError, KeyError, FileNotFoundError, IOError, etc.
  • Handling Blocks: try, except, else, and finally clauses, along with raise and assert statements.
  1. File Handling
  • File Types: Text files (.txt), binary files (.dat), and CSV files (.csv).
  • General File Operations: open(), close(), with statement, and file access modes (r, r+, w, w+, a, a+, rb, wb, ab, etc.).
  • Text Files: Reading (read(), readline(), readlines()), writing (write(), writelines()), and file pointer manipulation (seek(), tell()).
  • Binary Files: Serialization/deserialization using the pickle module (pickle.dump() and pickle.load()).
  • CSV Files: Reading and writing tabular data using the csv module (csv.reader(), csv.writer(), writerow(), writerows()).
  1. Data Structures (Stack)
  • Stack Concepts: Linear data structure and LIFO (Last-In, First-Out) principle.
  • Stack Operations: Implementation using Python lists (push via append(), pop via pop(), peek/display, and underflow/overflow checks).
  1. Python–Database Connectivity
  • MySQL Interface: Connecting Python to a MySQL database using mysql.connector.
  • Query Execution: connect(), cursor(), execute(), parameterized queries (%s or .format()), commit(), fetchone(), fetchmany(), fetchall(), and rowcount.

THANKS A LOT FOR READING

0 Upvotes

16 comments sorted by

6

u/danielroseman 8h ago

What is your question? What help are you actually looking for?

-5

u/timepassr 8h ago

how to get a good grasp and understanding this stuff

4

u/ANDRE_2512 8h ago

Learning requires visualization and interactivity. Books are great. Courses are too. But nothing helps you learn as effectively as visualization.

-5

u/timepassr 8h ago

so where can i learn with visualization

2

u/Correct_Rain_9438 7h ago

Your topic list matches the first chapters of the official Python tutorial almost one to one: variables and data types, operators, control flow, then data structures. Each section is short with self-contained examples, so one section per 45 minute session works well.

0

u/timepassr 7h ago

thanks

1

u/CIS_Professor 7h ago

i have to do it in under a month

Well, maybe you shouldn't have waited until the last month of the semester / school year to get started...

With that list, you're going to need a lot more than 45 minutes per day to achieve a passable level of mastery in all of them.

0

u/timepassr 7h ago

i actually have my exam on 30 th of march but im trying to rush things so i can revise it later on , thanks for your advise

1

u/CIS_Professor 7h ago

You said:

i have to do it in under a month

(emphasis mine)

That doesn't speak to "30 th of march" by any stretch of the imagination.

You aren't going to learn much by rushing. Since you are being tested, you must put in the time studying, writing, and fixing code. And that takes time.

1

u/timepassr 6h ago

thanks

2

u/Agawell 8h ago

Make stuff…

Work out what you need to do on paper - or as comments - and then turn what into code

A simple command line calculator is a good starting point…

It will get you doing loops, input and output, type conversion and if/elif/else etc

You can then expand on that to to make a scientific calculator by adding functions and graphing etc

1

u/BabyThanus 4h ago

I think this is the CBSE class 12 list almost word to word, so get the sample papers from the CBSE site. With 45 minutes a day I would skip courses and do the output questions and file handling from past papers. They repeat a lot lol, the stack program especially.

1

u/desrtfx but other languages pro 1h ago

This subreddit has a sidebar with a wiki with recommended learning resources.

Here is an excellent, textual course: MOOC Python Programming 2026 from the University of Helsinki.

Harvard's CS50p is also excellent.

Also, take a look at https://inventwithpython.com and https://automatetheboringstuff.com

Don't forget that you need ample practice, like on https://codingbat.com/python or on https://exercism.org and also write your own programs. Play around. Try things. Mess things up, fix them. Experiment.

Also, https://roadmap.sh/python