Implement a stack using a list.
His older sister, Meera, a college coder, peeked into his room. "Still stuck?"
Rohan stared at the blinking cursor on his screen. It was 11:30 PM. The Computer Science practical exam was in 10 hours. His Sumita Arora textbook lay open at Chapter 3: Working with Functions , but the pages might as well have been written in ancient Greek.
Instead of reading the solution, he forced himself to write code. He failed the first time (forgot to convert to lowercase). Failed the second time (indentation error). On the third attempt, it worked. ip sumita arora class 12
Rohan blinked. For the first time, the diagram from the book made sense. He grabbed the textbook and flipped to the unsolved exercises —questions he had skipped for months.
"Sumita Arora explains it with a chit system on page 187," she said. "A local variable is like a chit passed inside the small box. You can't use it outside. A global variable is like a chit on the main notice board. Everyone sees it."
"It's not magic," he said. "But it's the most patient teacher. It doesn't assume you know anything. It fails with you, then teaches you why you failed, then shows you how to succeed. Just don't wait until 11:30 PM the night before." Sumita Arora’s book isn’t just for reading—it’s for doing. The unsolved exercises, the margin notes, and the debugging questions are where the real learning happens. Don't skip them. Implement a stack using a list
Write a program to check if a string is a palindrome.
Meera didn't pick up the book. Instead, she picked up a marker and drew a big box on his whiteboard. "This is your main program." Then she drew a smaller box inside. "This is your function."
Half the class panicked. Rohan smiled.
When the examiner asked, "Explain variable scope in your function," Rohan drew two boxes on the rough sheet—exactly like Meera had shown him, exactly like of the book.
He wrote the code smoothly. No syntax errors. No logical flaws.
Rohan pointed to the dog-eared, coffee-stained on his shelf. It was 11:30 PM
He turned to . Sumita Ma'am's table compared Stack vs Queue with real-life examples: "Plates in a cafeteria" for LIFO. He coded push() and pop() in 15 minutes.