πŸ“š Computer β€” Computer

Programming Fundamentals, Languages, Algorithms, and Data Types (Programming 1)

Comprehensive study material on programming fundamentals, algorithms, flowcharts, syntax, and language translators

One-Liner Questions

What is the definition of a Computer Program?
A computer program is an ordered sequence of instructions that directs a computer to perform a specific task.
Tap to view answer
What is the primary objective of the Programming process?
To provide logical, executable, step-by-step instructions to a computer to solve complex problems.
Tap to view answer
What type of language is Machine Language?
It is a low-level language composed solely of binary digits (0 and 1) that a computer understands directly.
Tap to view answer
What is used to represent instructions in Assembly Language?
Instead of binary code, it uses abbreviated letters or symbolic codes called mnemonics (such as ADD, MOV).
Tap to view answer
What is the main feature of a High-Level Language?
It uses English-like words and mathematical symbols, making it easy to read, write, and understand.
Tap to view answer
What is an Algorithm?
A step-by-step sequence of logical instructions designed to solve a specific problem is called an algorithm.
Tap to view answer
What is the most important quality of a good algorithm?
It must be unambiguous, consist of a finite number of steps, and produce a definite output.
Tap to view answer
What is a Flowchart?
It is a graphical or pictorial representation of the logical flow of a process, algorithm, or program.
Tap to view answer
What is the Oval shape used for in a flowchart?
To represent the Start or End of a process (Terminal symbol).
Tap to view answer
What does a Parallelogram signify in a flowchart?
It represents Input or Output operations.
Tap to view answer
What is a Rectangle box used for in a flowchart?
To represent processing or calculation steps.
Tap to view answer
What does a Diamond shape indicate in a flowchart?
Decision-making or a conditional branch (True/False).
Tap to view answer
What is the function of Arrows (Flow Lines) in a flowchart?
To indicate the direction of logical flow.
Tap to view answer
What is Syntax?
The set of grammatical rules and structure governing how code is written in a programming language.
Tap to view answer
When does a Syntax Error occur?
When the grammatical rules or structure of the programming language are violated while writing code.
Tap to view answer
What does a Semantic Error mean?
When a program's syntax is valid, but its logical meaning or intended outcome is incorrect.
Tap to view answer
When does a Run-time Error occur?
When a program attempts to perform an invalid operation during execution (such as division by zero).
Tap to view answer
What is the role of a Language Translator?
To convert source code written in a high-level or assembly language into machine language (binary).
Tap to view answer
How does a Compiler work?
It reads the entire program's source code and translates it into machine code all at once.
Tap to view answer
What is the key difference between an Interpreter and a Compiler?
An interpreter executes code line by line, whereas a compiler translates the entire program at once.
Tap to view answer
What is the primary function of an Assembler?
To convert assembly language code into machine language (machine code).
Tap to view answer
What is Object Code?
The output machine code generated after a translator converts source code.
Tap to view answer
What is Source Code?
The human-readable code written by a programmer in a high-level programming language.
Tap to view answer
What does the term 'Bug' mean in programming?
An error, flaw, or defect in a program that prevents it from producing the expected output.
Tap to view answer
What is the Debugging process?
The process of finding and fixing errors (bugs) in a program.
Tap to view answer
Which language was the First Generation Programming Language (1GL)?
Machine Language.
Tap to view answer
What falls under Second Generation Languages (2GL)?
Assembly Language.
Tap to view answer
What characterizes Third Generation Languages (3GL)?
They are high-level procedural languages such as C, C++, and Java.
Tap to view answer
What is the primary focus of Fourth Generation Languages (4GL)?
On specifying desired results rather than step-by-step procedures, such as database query languages (SQL).
Tap to view answer
Which technology are Fifth Generation Languages (5GL) based on?
Artificial Intelligence (AI) and Natural Language Processing (NLP).
Tap to view answer
What is the foundation of Procedural Programming?
Dividing a program into smaller tasks or subroutines (functions/procedures).
Tap to view answer
What are the core concepts of Object-Oriented Programming (OOP)?
Class, Object, Inheritance, and Polymorphism.
Tap to view answer
What is the use of Pseudocode in algorithms?
It expresses a program's logical structure in plain English without strict programming syntax.
Tap to view answer
What is the purpose of the Connector symbol (Circle) in a flowchart?
To link different parts or pages of a large flowchart together.
Tap to view answer
Which two factors primarily determine the efficiency of an algorithm?
Time Complexity and Space Complexity.
Tap to view answer
Where is Big-O Notation used?
To measure the performance and time/space complexity of an algorithm.
Tap to view answer
Which language is an example of a Middle-Level Language?
The C programming language, as it supports both low-level and high-level features.
Tap to view answer
What are the roles of a Loader and a Linker?
Linking multiple object modules together and loading the translated program into main memory.
Tap to view answer
What are prominent examples of Interpreted Languages?
Python and JavaScript.
Tap to view answer
What are prominent examples of Compiled Languages?
C and C++.
Tap to view answer
What is the main advantage of Structured Programming?
It improves code readability and simplifies maintenance.
Tap to view answer
What is the biggest limitation of a Flowchart?
For very large and complex programs, flowcharts become exceedingly difficult to draw and understand.
Tap to view answer
What is the importance of 'Comments' in programming?
They are written to explain code logic and are ignored (not executed) by the compiler.
Tap to view answer
How is a Variable defined in programming?
It is a named location in computer memory that stores data or a value.
Tap to view answer
What is the difference between a Constant and a Variable?
A constant's value cannot change during program execution, whereas a variable's value can be modified.
Tap to view answer
What is the function of Data Types in programming?
To specify what kind of data (such as integers, decimals, or characters) a variable will store.
Tap to view answer
What do Operators do in programming?
They perform mathematical, logical, or relational operations on variables and values.
Tap to view answer
What is the use of Control Statements?
To control the flow of program execution (such as if-else and loops).
Tap to view answer
Why is a Loop used in programming?
To execute the same instruction or block of code repeatedly.
Tap to view answer
What is the main difference between a For Loop and a While Loop?
A for loop is typically used for a known number of iterations, whereas a while loop is condition-based.
Tap to view answer
What is the main advantage of a Function or Subroutine?
Code reusability and reducing overall program complexity.
Tap to view answer
What is Recursion?
When a function calls itself within its own definition.
Tap to view answer
What is the main characteristic of an Array data structure?
It stores elements of the same data type in contiguous memory locations.
Tap to view answer
What kind of variable is a Pointer?
A variable that stores the memory address of another variable.
Tap to view answer
What is a Structure in the C language?
A user-defined data type that groups variables of different data types together.
Tap to view answer
What is the use of File Handling in programming?
To permanently store and read data on secondary storage disks.
Tap to view answer
What condition is required for the Binary Search algorithm to work?
The data list must always be sorted.
Tap to view answer
How does Linear Search work?
By sequentially comparing each element of the list one by one against the target value.
Tap to view answer
How does the Bubble Sort algorithm work?
By repeatedly comparing adjacent elements and swapping them into the correct order.
Tap to view answer
Which technique is Merge Sort based on?
The 'Divide and Conquer' technique.
Tap to view answer
Which principle does a Stack data structure follow?
LIFO (Last In, First Out) β€” the last element inserted is the first one removed.
Tap to view answer
What is the operating principle of a Queue data structure?
FIFO (First In, First Out) β€” the first element inserted is the first one removed.
Tap to view answer
What is the basic unit of a Linked List called?
A Node, which contains data and the address (pointer) to the next node.
Tap to view answer
What type of relationship does a Tree data structure represent?
A hierarchical or parent-child relationship.
Tap to view answer
What is the maximum number of children a node in a Binary Tree can have?
Each node can have at most two children.
Tap to view answer
What does a Graph data structure consist of?
A collection of vertices (nodes) and edges.
Tap to view answer
What is the defining property of a Binary Search Tree (BST)?
Values in the left subtree are less than the root, and values in the right subtree are greater.
Tap to view answer
What is the primary use of a Hash Table?
Fast data retrieval based on key-value pairs.
Tap to view answer
Why are Coding Standards important?
To keep code readable, standardized, and easy for other team members to understand.
Tap to view answer
What is the function of a Version Control System (such as Git)?
To track different versions of code and facilitate collaborative development.
Tap to view answer
What is the objective of Software Testing?
To uncover hidden defects in a program and ensure software quality.
Tap to view answer
What is White-box Testing?
A testing method that examines the internal structure, code, and logic of a program.
Tap to view answer
What is Black-box Testing?
Testing only the input and output behavior without examining the internal code.
Tap to view answer
What does Unit Testing involve?
Individual testing of the smallest independent component or function of a program.
Tap to view answer
When is Integration Testing performed?
When multiple separate modules or components are combined and tested together.
Tap to view answer
What is System Testing?
Testing the complete, integrated software system against its specified requirements.
Tap to view answer
What is the main difference between Alpha and Beta testing?
Alpha testing is performed by the internal development team, whereas Beta testing is conducted by real end-users.
Tap to view answer
What is the base (radix) of the Binary Number System?
Base 2 (digits 0 and 1).
Tap to view answer
What is the base of the Hexadecimal Number System?
Base 16 (0 to 9 and A to F).
Tap to view answer
What is the base of the Octal Number System?
Base 8 (digits 0 to 7).
Tap to view answer
What is ASCII code primarily used for?
Assigning numeric (binary) values to English characters and standard symbols.
Tap to view answer
What is the advantage of UNICODE?
It supports scripts and characters from virtually all languages worldwide.
Tap to view answer
What is meant by 'Compilation Time' in programming?
The time taken by a compiler to translate source code into machine code.
Tap to view answer
What is 'Remote Debugging' in programming?
Finding and fixing errors in a program running on another computer or server over a network.
Tap to view answer
What does an Integrated Development Environment (IDE) provide?
A unified software platform for writing, editing, compiling, and debugging code.
Tap to view answer
What are well-known examples of an IDE?
Visual Studio Code, Eclipse, or PyCharm.
Tap to view answer
What does the 'Finiteness' property of an algorithm mean?
An algorithm must always terminate after a finite number of steps.
Tap to view answer
What does 'Definiteness' in an algorithm mean?
Every instruction must be clear, precise, and free from ambiguity.
Tap to view answer
How many paths typically branch out from a Decision Symbol in a flowchart?
Usually two (Yes/No or True/False).
Tap to view answer
What is the primary role of a Linker among language translators?
To combine various object files and libraries into a single executable file.
Tap to view answer
What type of language is Python?
It is a high-level, interpreted, and object-oriented programming language.
Tap to view answer
What is the most notable feature of Java?
'Write Once, Run Anywhere' (WORA), meaning platform independence.
Tap to view answer
Who developed the C language and when?
Dennis Ritchie in 1972 at Bell Labs.
Tap to view answer
What is 'Encapsulation' in Object-Oriented Programming?
Binding data and methods together within a single unit (Class).
Tap to view answer
What does 'Polymorphism' mean in programming?
The ability of a function or operator with the same name to take different forms or behaviors in different contexts.
Tap to view answer
What is the advantage of Inheritance?
Reusing the properties and methods of an existing class in a new class.
Tap to view answer
What is the main purpose of Abstraction?
Showing only essential details while hiding complex internal implementation details.
Tap to view answer
Why is a 'Logical Error' difficult to detect in programming?
Because the compiler does not issue any error message; the program simply produces incorrect output.
Tap to view answer
What is the biggest drawback of Machine Language?
It is machine-dependent and extremely difficult to remember and understand.
Tap to view answer
What advantage does Assembly Language have over Machine Language?
It uses easy-to-remember mnemonics instead of raw binary code.
Tap to view answer
What is the primary advantage of High-Level Languages?
They are machine-independent and much easier to learn and understand.
Tap to view answer
Quick Reference
Key Facts & Contributions
Programming 1
ConceptPrimary FunctionKey Characteristic
AlgorithmDesigning step-by-step logical instructions to solve a problemClear, finite steps and a machine-independent logical structure
FlowchartVisually representing the logical flow of a program or algorithmVisual representation using standardized geometric shapes (symbols)
CompilerTranslating high-level source code into complete machine code all at onceFast execution; reports the complete list of errors together
InterpreterReading and executing source code line by lineEasy line-by-line debugging, but comparatively slower execution speed
AssemblerTranslating assembly language mnemonics into machine language (binary)Low-level hardware control and processor-specific translation
LinkerCombining multiple object modules and library files togetherGenerates a single executable file
LoaderLoading an executable program into main memory (RAM)Prepares the program for execution by the processor
No matching content found.