ITP Week 1
ITP Week 1
Key Takeaways:
• A computer is defined as a device that takes inputs from input devices,
performs operations based on programs, and generates outputs.
• The main components of a computer include:
– Motherboard (central processing unit or processor)
– Memory units (RAM)
– Input/output buses
– Power supply unit (SMPS)
• A computer can take various types of inputs from input devices such as
keyboards, mice, scanners, and microphones.
• Outputs can be generated in various forms including written files, printed
documents, display on screens, or audio through speakers.
Computer Components:
• Motherboard (hosts processor and memory units)
– Processor (central processing unit or CPU): brain of the system
– Memory units (RAM): stores data while processor is executing oper-
ations
– Input/output buses: enables communication between devices and
CPU
Key Concepts:
• Hardware refers to physical components such as motherboard, processor,
RAM, etc.
• Software refers to set of instructions that tells a computer what task to
perform.
Video Key Points:
The video explains the basics of computers and their operation. It highlights
various components of a desktop system including the motherboard, CPU, mem-
ory units, power supply unit (SMPS), external hard disk drive, and buses for
communication between devices. The concept of hardware vs software is also
discussed in detail.
Summary:
• What is Computer Programming?: Writing programs or source code
for computing systems to understand and perform specific tasks.
• Benefits of Programming: Used in various disciplines, including
medicine, physics, sports, education, and more; creates a career path on
its own.
• Examples of Programming: Mobile apps, online educational platforms
(e.g., Coursera), software like Excel or Tally, e-commerce portals, medical
imaging analysis (e.g., retinal fundus image analysis), and more.
1
• Communicating with Computers: Writing programs in a language
that computers can understand; natural languages are ambiguous, redun-
dant, or complex for computers to comprehend.
• Abstraction Level: Programming Languages: Serves as an abstrac-
tion level between humans and computers; programming languages (e.g.,
C) act as a bridge to convert human-like constructs into machine-readable
format (zeros and ones).
• High-Level Programming Language: C: General-purpose, indepen-
dent of platform, compiler-based language that allows for English-like con-
structs.
Key Takeaways:
1. Computer programming is used in various disciplines.
2. It creates a career path on its own.
3. Natural languages are not suitable for programming due to ambiguity,
redundancy, or complexity.
4. Programming languages (e.g., C) act as an abstraction level between hu-
mans and computers.
Main Points:
• Examples of programming usage include medicine, physics, sports, educa-
tion, and more.
• Programming creates a career path on its own.
• Natural language limitations prevent direct communication with comput-
ers.
• Abstraction level: programming languages serve as a bridge to convert
human-like constructs into machine-readable format (zeros and ones).
• C is an example of a high-level programming language that allows for
English-like constructs.
Summary: Key Takeaways on Operating Systems and Software
Types of Software
• Program: A set of instructions in a specific programming language to
accomplish a task.
• Software: A collection of programs that can accomplish certain tasks.
System Software vs Application Software
• System Software: Manages devices, provides a conducive platform for
other software to run. Examples: operating system, device drivers.
• Application Software: Domain-specific software for specific tasks. Ex-
amples: spreadsheets, browsers, video games.
Operating System (OS)
• A crucial component of system software that manages computer resources
like hardware and memory.
2
• Acts as an intermediary between programs and hardware resources.
• Manages resource allocation based on user privileges.
• Without OS, the system cannot run smoothly or efficiently.
Key Features of Operating Systems
• Resource manager: allocates resources to users based on privilege levels.
• Initialization: loads necessary software for smooth system operation.
• Graphical User Interface (GUI): provides a conducive environment for
other software to function properly.
Types of Operating Systems
• Examples: macOS, iOS, Android, CentOS, Linux, Windows
Conclusion
The operating system is a vital component that manages computer resources
and provides a platform for other software to run. It acts as a resource man-
ager, allocating resources based on user privileges and ensuring smooth system
operation. Understanding the role of the OS and its types can help users make
informed decisions when choosing an operating system for their devices.
Summary: How Programs Get Executed
Understanding Program Execution
• A program is written in a high-level language (e.g., C) and stored on the
disk.
• The program needs to be converted into machine-readable format through
compilation.
• After compilation, the operating system loads the program onto Random
Access Memory (RAM), which serves as temporary storage.
Types of Memory
• Volatile Memory: RAM, where data is lost when power supply goes off.
Examples: RAM sticks, hard disk cache.
• Non-Volatile Memory: Permanent memory that retains data even after
power supply goes off. Examples: Hard disks, flash drives.
Program Execution Process
1. Compilation: The program written in a high-level language is converted
into machine-readable format (0s and 1s) by the compiler.
2. Loading onto RAM: The compiled program is loaded onto Random
Access Memory (RAM), where it awaits execution by the processor.
3. Execution on CPU: The operating system calls the program to be exe-
cuted, and the processor processes each instruction line-by-line.
Program Execution and Processes
• A running program is called a sub-process or process.
3
• Multiple programs can run simultaneously as separate processes in mem-
ory.
• Programs under execution are visible in the Task Manager as processes.
Summary: Algorithms and Flowcharts
What are Algorithms?
• A collection of finite and unambiguous steps to be followed to arrive at
the solution of a computation problem
• Used by programmers as a pre-programming tool to write programs
Difference between Algorithm and Flowchart
• An algorithm is represented in text format with numbered steps, standard
operators, and keywords (e.g., ”begin”, ”end”)
• A flowchart is a pictorial representation using different symbols for various
types of steps (e.g., start, input/output, computation, decision-making)
Key Constructs of Algorithms and Flowcharts
• Sequencing: executing a sequence of statements in a sequential order
• Decision-making: choosing from many alternatives and then selecting
which set of statements to execute
• Repetition: executing one or group of statements in a loop in an iterative
manner
Symbols Used in Flowcharts
• Start (oval-shaped)
• Input/output (parallelogram): for getting inputs or outputs
• Computation (rectangle): for storing results and outputting values
• Decision-making (diamond): with one flow line at the top, one at the
bottom, and one at the right side
• Connectors: to connect different portions of flowcharts
Example Algorithm
• Begin
– Take input a and b
– Compute a + b into sum
– Output sum
– End
Example Flowchart
• Start → Input/Output (a, b) → Computation (rectangle) → Decision-
making (diamond) → Connector → Stop
Summary: Incorporating Decision-Making into Flowcharts
Incorporating Decision-Making into Algorithms
• Using if statements and else clauses to break from sequential execution
4
• If the condition is true, execute one set of statements; otherwise, execute
another set
Translating Decision-Making into a Flowchart
1. Start: Begin with a start symbol in the flowchart.
2. Input: Use a parallelogram to represent taking input (in this case, n).
3. Decision-Making: Use a diamond symbol to check if the condition is
true (e.g., ”Is n greater than 0?”).
• If the answer is yes: execute one set of statements.
• If the answer is no: execute another set of statements.
Example Flowchart
1. Start → Input/Output (n) → Diamond (Is n > 0?)
2. If Yes:
• Output ”n is positive”
3. Else:
• Output ”Error”
4. Stop: Once either the first or second output path is executed, stop.
Key Takeaway
• Decision-making in flowcharts involves using a diamond symbol to repre-
sent a two-way branching decision.
• The outcome of the decision determines which set of statements to execute
next.
Summary: Incorporating Iterative Construct into Flowcharts
Understanding Iterative Construct
• An iterative construct involves a statement or group of statements inside
a loop that are repeated until a certain condition is met.
• Essential for solving repetitive problems, such as computing the sum of n
natural numbers.
Converting Algorithm to Flowchart
1. Start: Begin with a start symbol in the flowchart.
2. Input: Use a parallelogram to represent inputting the value of n (e.g.,
”Input n”).
3. Initialize Variables: Represent initializing index variable i to 1 and sum
to 0 using rectangles.
4. Decision-Making: Use a diamond symbol to check if the condition is
true: ”Is i less than or equal to n?”
• If yes, execute statements inside loop (add i to sum, increment i).
5. Loop Continuation: Connect arrows from end of loop back to decision-
making step.
5
6. Termination Condition: When condition becomes false (”i > n”), out-
put the value of sum.
7. Stop: Finalize flowchart with a stop symbol.
Key Takeaways
• Iterative construct involves using loops and repetition in a flowchart.
• Decision-making symbols (diamonds) are used to create loop conditions.
• Arrows connect loop iterations back to decision-making steps, ensuring
logical flow.
• Flowcharts can pictorially represent complex algorithms involving itera-
tion.
Summary: Computer Components and Programming
Understanding Computers and Programming
• A computer is an electronic device that can store, process, and communi-
cate data.
• Different components of a computer include:
– CPU (Central Processing Unit)
– Memory (RAM)
– Storage Devices (HDD/SSD)
– Input/Output Devices
• Computer programming involves writing instructions in a language the
computer understands.
Computer Programming
• Benefits of computer programming include:
– Improved efficiency and accuracy
– Increased productivity and creativity
– Ability to solve complex problems and make informed decisions
Writing Programs
• Need for a programming language due to computers only understanding
binary code (zeros and ones).
• High-level languages like C require conversion to machine-readable format
using compilers.
Program Execution
• Compiled program stored on hard disk.
• Program loaded onto RAM when executed.
• Processor executes instructions line-by-line.
Algorithms and Flowcharts
• Algorithm: a sequence of finite, unambiguous steps to solve a problem
(written in simple English with mathematical operators).
6
• Flowchart: a pictorial representation of the steps to solve a scientific prob-
lem (includes symbols for input/output, decision-making, and repeated
tasks).
Key Takeaways
• Computer components work together to process data.
• Programming languages are essential for computers to understand human
instructions.
• Algorithms and flowcharts provide structured approaches to solving prob-
lems.