💻 Introduction to Programming
• Course: Introduction to Computers and Programming
• Instructor: Karmanay Gupta
• A program is a set of instructions that tells a computer
what to do.
• This course focuses on writing such programs.
🤔 Why Do We Need Programming?
• Computers are versatile because they can be
programmed.
• They follow the instructions in the program.
• Without programs, computers can’t function.
• Programming enables computers to do a variety of
tasks.
💡 What is Programming?
• Programming operates hardware and solves problems.
• It is both an Art (creativity) and Science (structure).
• No single right way to solve a problem.
• This course teaches the art and science of programming.
️
🖥️Hardware and Software
• Hardware: Physical components of a computer system.
• Software: Programs that run on a computer.
• Examples of hardware: CPU, Memory, Storage Devices.
• Software includes OS and Application Programs.
🧠 Central Processing Unit (CPU)
• CPU is the heart and brain of the computer.
• Fetch → Decode → Execute instructions.
• Consists of Control Unit & Arithmetic Logic Unit (ALU).
• Performs mathematical and logical operations.
💾 Main Memory
• Holds information that the CPU needs to access quickly.
• Volatile memory: Loses content when power is off.
• Memory divided into bytes (8 bits each).
• Each byte is accessed via a unique address.
📦 Secondary Storage
• Holds data long-term: Hard Drive, SSD, USB, CD-ROM.
• Slower than RAM but non-volatile.
• Used to store documents, programs, and media.
• Loaded into main memory when needed.
⌨️Input and Output Devices
• Input Devices: Keyboard, Mouse, Scanner, USB.
• Output Devices: Monitor, Printer, Speakers.
• Input: Data collected from outside world.
• Output: Data sent to outside world.
🧮 Program Development Cycle
• 1. Analyze: Understand the problem.
• 2. Design: Plan a solution (algorithm).
• 3. Code: Translate algorithm into code.
• 4. Test: Find and fix errors.
• 5. Document: Write explanations for users/developers.
🧾 Algorithm Example (Postage
Stamps)
• Input: Number of pages.
• 1 stamp per 5 pages. Round up.
• Validate that input is a number.
• Calculate stamps = ceil(pages / 5).
• Output: Number of stamps needed.
📊 Programming Tools
• Flowcharts: Visual logic diagrams.
• Hierarchy Charts: Show structure of modules.
• Pseudocode: Informal code-like English statements.
• No official syntax for pseudocode.

Final_Intro_Programming_Presentation.pptx

  • 1.
    💻 Introduction toProgramming • Course: Introduction to Computers and Programming • Instructor: Karmanay Gupta • A program is a set of instructions that tells a computer what to do. • This course focuses on writing such programs.
  • 2.
    🤔 Why DoWe Need Programming? • Computers are versatile because they can be programmed. • They follow the instructions in the program. • Without programs, computers can’t function. • Programming enables computers to do a variety of tasks.
  • 3.
    💡 What isProgramming? • Programming operates hardware and solves problems. • It is both an Art (creativity) and Science (structure). • No single right way to solve a problem. • This course teaches the art and science of programming.
  • 4.
    ️ 🖥️Hardware and Software •Hardware: Physical components of a computer system. • Software: Programs that run on a computer. • Examples of hardware: CPU, Memory, Storage Devices. • Software includes OS and Application Programs.
  • 5.
    🧠 Central ProcessingUnit (CPU) • CPU is the heart and brain of the computer. • Fetch → Decode → Execute instructions. • Consists of Control Unit & Arithmetic Logic Unit (ALU). • Performs mathematical and logical operations.
  • 6.
    💾 Main Memory •Holds information that the CPU needs to access quickly. • Volatile memory: Loses content when power is off. • Memory divided into bytes (8 bits each). • Each byte is accessed via a unique address.
  • 7.
    📦 Secondary Storage •Holds data long-term: Hard Drive, SSD, USB, CD-ROM. • Slower than RAM but non-volatile. • Used to store documents, programs, and media. • Loaded into main memory when needed.
  • 8.
    ⌨️Input and OutputDevices • Input Devices: Keyboard, Mouse, Scanner, USB. • Output Devices: Monitor, Printer, Speakers. • Input: Data collected from outside world. • Output: Data sent to outside world.
  • 9.
    🧮 Program DevelopmentCycle • 1. Analyze: Understand the problem. • 2. Design: Plan a solution (algorithm). • 3. Code: Translate algorithm into code. • 4. Test: Find and fix errors. • 5. Document: Write explanations for users/developers.
  • 10.
    🧾 Algorithm Example(Postage Stamps) • Input: Number of pages. • 1 stamp per 5 pages. Round up. • Validate that input is a number. • Calculate stamps = ceil(pages / 5). • Output: Number of stamps needed.
  • 11.
    📊 Programming Tools •Flowcharts: Visual logic diagrams. • Hierarchy Charts: Show structure of modules. • Pseudocode: Informal code-like English statements. • No official syntax for pseudocode.