Skip to content
πŸ“š Free notes, MCQ tests & past papers β€” FBISE & BISE Rawalpindi
πŸ“’ Latest Updates

FBISE 2nd Year Computer Science Unit 8 Entrepreneurship in Digital Age: Short and Long Questions with Answers 2027

Reviewed by Sadia Shahid, Senior Science teacher (Maths, Physics, Chemistry, Biology, Computer Science)

Here are the important short and long questions of Unit 8, Entrepreneurship in Digital Age, from the Federal Board (FBISE) 2nd Year Computer Science course (HSSC-II, Intermediate Part II), solved in full for the Annual Examination 2027.

Unit 8: Entrepreneurship in Digital Age
Class 2nd Year (HSSC-II), Federal Board
Subject Computer Science
Contents Short and long questions with answers
Exam FBISE Annual Examination 2027

Short Questions with Answers: Unit 8

No questions from these papers.

Other Topics (Old Curriculum 2009, C++)

Q1. Why is memory management required? Give any three reasons. [Model Paper (Old Curriculum 2009)] (03)

Answer:

  • Allocation of memory to processes: each program needs memory to run; memory management allocates and deallocates memory efficiently as processes start and finish.

  • Protection: it keeps each process in its own memory space, so one process cannot access or corrupt another’s memory or the OS.

  • Efficient use and multitasking: it lets many programs run together, reduces fragmentation and uses virtual memory (paging) to run programs larger than physical RAM.

Q2. Write down any three differences between process and thread. [Model Paper (Old Curriculum 2009)] (03)

Answer:

Process Thread
A program in execution; an independent unit A lightweight unit of execution within a process
Has its own separate memory space (address space) Shares the memory and resources of its process
Creation and context switching are slow (heavy) Creation and switching are fast (light)
Communication between processes is difficult (IPC) Threads communicate easily through shared memory

Q3. Write down the reasons of the following invalid variable names: (a) 3a (b) S$ (c) long [Model Paper (Old Curriculum 2009)] (03)

Answer:

  • (a) 3a: invalid because a variable name cannot start with a digit; it must begin with a letter or underscore.

  • (b) S$: invalid because special characters like $ are not allowed; only letters, digits and underscore are permitted.

  • (c) long: invalid because it is a reserved keyword (a data type) in C++ and cannot be used as an identifier.

Q4. Differentiate between unary and binary operators with one example each. [Model Paper (Old Curriculum 2009)] (03)

Answer:

Unary operator Binary operator
Works on one operand Works on two operands
e.g. increment ++, decrement –, unary minus –, logical NOT ! e.g. arithmetic +, –, *, /, %; relational <, >; logical &&
Example: x++; or –a Example: a + b; or x > y

Q5. Write down any three differences between text and binary files. [Model Paper (Old Curriculum 2009)] (03)

Answer:

Text file Binary file
Data stored as readable characters (ASCII) Data stored in binary (machine) format
Can be read and edited in any text editor Cannot be read by a text editor
Character conversions (newline) take place; takes more space No conversions; takes less space, faster access

Q6. How is constructor different from destructor? List down any three differences. [Model Paper (Old Curriculum 2009)] (03)

Answer:

Constructor Destructor
Special member function that initialises an object Special member function that destroys/cleans up an object
Called automatically when the object is created Called automatically when the object goes out of scope or is deleted
Same name as class, e.g. Student() Same name preceded by a tilde, e.g. ~Student()
Can have parameters and can be overloaded Has no parameters and cannot be overloaded

Q7. Write down any three responsibilities of system analyst. [Model Paper (Old Curriculum 2009)] (03)

Answer:

  • Studying the existing system and gathering requirements through interviews, questionnaires and observation of users.

  • Analysing problems and doing a feasibility study: identifying needs and proposing technical, economic and operational solutions.

  • Designing the new system and communicating: preparing specifications (DFDs, flowcharts) for programmers, coordinating between users and developers, and helping with testing, implementation and training.

Q8. Write down any three objectives of SDLC. [Model Paper (Old Curriculum 2009)] (03)

Answer:

  • To develop a high-quality system that meets user requirements, is correct and reliable.

  • To complete the project within time and budget through proper planning and control of each phase.

  • To provide a systematic, structured approach: clear phases, documentation and easy maintenance, which reduces risks and errors.

Q9. What will be displayed after executing the following statements? [Model Paper (Old Curriculum 2009)] (03)

int x = 3, y = 17;

cout << x / y << “t” << y / x << “t” << x % y;

Answer:

  • x / y = 3 / 17 = 0 (integer division)

  • y / x = 17 / 3 = 5 (integer division)

  • x % y = 3 % 17 = 3 (remainder)

  • Output: 0 5 3 (separated by tabs)

Q10. Write down the output of the following statements: [Model Paper (Old Curriculum 2009)] (03)

(a) A = (x > 0) && (y < 10) where x = 5, y = 15

(b) S = 13 + 21 % 4

(c) m *= 2; where m = 12

Answer:

  • (a) A = (5 > 0) && (15 < 10) = true && false = 0 (false)

  • (b) S = 13 + 21 % 4 = 13 + 1 = 14 (% has higher precedence)

  • (c) m *= 2 means m = m Γ— 2 = 12 Γ— 2 = 24

Q11. Write down the purpose and syntax of break statement. [Model Paper (Old Curriculum 2009)] (1.5+1.5)

Answer:

  • Purpose: break terminates (exits) the loop or switch statement immediately, and control passes to the statement after the loop/switch.

  • Syntax:

break;

  • Example:

for (int i = 1; i <= 10; i++) {

if (i == 5) break; // loop stops when i is 5

cout << i << ” “; // output: 1 2 3 4

}

Q12. Write down the purpose and syntax of exit() function. [Model Paper (Old Curriculum 2009)] (1.5+1.5)

Answer:

  • Purpose: exit() terminates the whole program immediately and returns control to the operating system. It is defined in <cstdlib> (stdlib.h).

  • Syntax:

exit(status); // exit(0) = normal termination, exit(1) = error

  • Example:

if (marks < 0) { cout << “Invalid”; exit(1); }

Q13. Why is it important to write comments in a program? Also differentiate its two types. [Model Paper (Old Curriculum 2009)] (1+2)

Answer:

  • Importance: comments explain the purpose and logic of the code, making the program easy to read, understand, debug and maintain by the programmer or others. The compiler ignores them.

  • Types:

  • Single-line comment: starts with //, e.g. // calculate area

  • Multi-line (block) comment: enclosed between /* and */ and can extend over several lines, e.g. /* This program finds the sum of two numbers */

Q14. What is the difference between constant and variable? Give examples also. [Model Paper (Old Curriculum 2009)] (1+2)

Answer:

Constant Variable
Value cannot be changed during program execution Value can be changed during execution
Declared with const keyword or #define Declared with a data type
e.g. const float PI = 3.14; e.g. int age = 16; age = 17;

Q15. Write down the output of the following program segment: [Model Paper (Old Curriculum 2009)] (03)

char c = ‘A’;

do

{

cout << c << “t”;

c = c + 2;

}

while (c <= ‘K’);

Answer:

  • c starts at ‘A’ and increases by 2 each time while c ≀ ‘K’: A, C, E, G, I, K.

  • Output: A C E G I K

Q16. Write down the output of the following program segment: [Model Paper (Old Curriculum 2009)] (03)

int values[] = {4, 17, 20, 9, 23};

cout << values[2] << “n”;

cout << ++values[0] << “n”;

cout << values[1]++ << “n”;

Answer:

  • values[2] = 20

  • ++values[0]: pre-increment 4 β†’ 5, prints 5

  • values[1]++: post-increment prints 17, then it becomes 18

  • Output (each on new line):

20

5

17

Q17. Rewrite the following statement using if-else statement: [Model Paper (Old Curriculum 2009)] (03)

cout << (((num % 2) == 0) ? “Even n” : “Odd n”);

Answer:

if ((num % 2) == 0)

cout << “Even n”;

else

cout << “Odd n”;

Q18. Convert the following while loop to a for loop such that the output remains same. [Model Paper (Old Curriculum 2009)] (03)

int i = 20;

while (i > 0)

{

cout << i << “t”;

i = i – 2;

}

Answer:

for (int i = 20; i > 0; i = i – 2)

{

cout << i << “t”;

}

  • Output in both cases: 20 18 16 14 12 10 8 6 4 2

Q19. What is the difference between array size and index? Illustrate with example. [Model Paper (Old Curriculum 2009)] (1+2)

Answer:

  • Array size is the total number of elements an array can hold, fixed at declaration. Index is the position number of an element, starting from 0 to size – 1.

  • Example:

int marks[5] = {70, 80, 65, 90, 85};

  • Size = 5 (elements). Index ranges from 0 to 4; marks[0] = 70 and marks[4] = 85. marks[5] is out of range.

Q20. Differentiate between string and array with one example of each. [Model Paper (Old Curriculum 2009)] (1+2)

Answer:

String Array
Sequence of characters, terminated by a null character ‘’ Collection of elements of any one data type (int, float, char)
Can be read and printed as a whole Elements are generally processed one by one
e.g. char name[] = “Ali”; or string s = “Ali”; e.g. int num[3] = {10, 20, 30};

Q21. Compare local and static variables in terms of scope, lifetime and storage duration. [Model Paper (Old Curriculum 2009)] (03)

Answer:

Feature Local variable Static (local) variable
Scope Only within the block/function where declared Also only within its block/function
Lifetime Created on entering the function, destroyed on exit Exists for the whole program run; retains its value between calls
Storage Stack memory (automatic storage); garbage value if not initialised Static/data memory; initialised once (default 0)

Q22. Write down any three differences between actual and formal parameters. [Model Paper (Old Curriculum 2009)] (03)

Answer:

Actual parameters Formal parameters
Values or variables passed in the function call Variables declared in the function definition/header
e.g. sum(a, b); – a and b are actual e.g. int sum(int x, int y) – x and y are formal
Can be constants, variables or expressions Must be variables, with data types
Exist in the calling function Created when the function is called; local to the function

Q23. Rewrite the program segment after removing errors: [Model Paper (Old Curriculum 2009)] (03)

int a{10}, i;

cout >> ” enter ten numbers ;

for (i = 0; i < 10; i–)

cin << a{i};

Answer:

  • Corrected code:

int a[10], i;

cout << “Enter ten numbers”;

for (i = 0; i < 10; i++)

cin >> a[i];

  • Errors fixed: square brackets [ ] for arrays; << with cout and >> with cin; closing quotation mark; i++ instead of i– (otherwise an infinite loop).

Q24. Consider the array definition: float table[5][5]; [Model Paper (Old Curriculum 2009)] (1+2)

(a) How many elements does the array have?

(b) Write statement that assigns 36.5 to the first element of array.

Answer:

  • (a) table[5][5] has 5 Γ— 5 = 25 elements.

  • (b) table[0][0] = 36.5;

Q25. What is reference operator? Give example. [Model Paper (Old Curriculum 2009)] (2+1)

Answer:

  • The reference (address-of) operator & returns the memory address of a variable. It is also used to create a reference (alias) of a variable.

  • Example:

int x = 10;

cout << &x; // prints address of x, e.g. 0x61ff08

int *p = &x; // pointer p stores address of x

Q26. Write down the purpose of sizeof() function with example. [Model Paper (Old Curriculum 2009)] (2+1)

Answer:

  • Purpose: sizeof() is an operator that returns the number of bytes of memory occupied by a variable or data type.

  • Example:

cout << sizeof(int); // 4

cout << sizeof(float); // 4

cout << sizeof(double); // 8

Q27. Define a class Student that contains public data members including function get(). [Model Paper (Old Curriculum 2009)] (03)

Answer:

class Student {

public:

int rollNo;

char name[30];

float marks;

void get() {

cout << “Enter roll no, name and marks: “;

cin >> rollNo >> name >> marks;

}

};

Q28. Write a C++ program that reads base and height of a triangle and displays its area by using formula: area = Β½ Γ— b Γ— h [Model Paper (Old Curriculum 2009)] (03)

Answer:

#include <iostream>

using namespace std;

int main() {

float b, h, area;

cout << “Enter base and height: “;

cin >> b >> h;

area = 0.5 * b * h;

cout << “Area of triangle = ” << area;

return 0;

}

Q29. Write down the difference between single user and multi user operating systems. [Annual 2026 – Old Curriculum 2009] (1.5+1.5)

Answer:

Single-user OS Multi-user OS
Allows only one user to use the computer at a time Allows many users to use the system at the same time
Simpler; less security needed Needs user accounts, permissions and strong security
e.g. MS-DOS, Windows (personal use) e.g. UNIX, Linux servers, Windows Server

Q30. Write down the purpose of following escape sequences: (I) a (II) b (III) n [Annual 2026 – Old Curriculum 2009] (1Γ—3)

Answer:

  • a (alert): produces a beep sound (bell).

  • b (backspace): moves the cursor one position back.

  • n (new line): moves the cursor to the beginning of the next line.

Q31. Write down the reasons of the following invalid variable names: (I) 2a (II) S$ (III) int [Annual 2026 – Old Curriculum 2009] (1+1+1)

Answer:

  • (I) 2a: invalid because it starts with a digit.

  • (II) S$: invalid because it contains the special character $.

  • (III) int: invalid because it is a reserved keyword.

Q32. Write down the purpose and syntax of break statement. [Annual 2026 – Old Curriculum 2009]

Answer:

  • Purpose: break immediately terminates the loop or switch statement in which it appears, and control moves to the next statement after it.

  • Syntax:

break;

  • e.g. in a switch, break after each case prevents fall-through to the next case.

Q33. Write down any three differences between text and binary files. [Annual 2026 – Old Curriculum 2009] (1Γ—3)

Answer:

Text file Binary file
Human-readable characters Data in binary form, not human-readable
Can be opened in a text editor Needs a special program
Larger, slower (character conversion) Smaller, faster (no conversion)

Q34. How is constructor different from destructor? List down any three differences. [Annual 2026 – Old Curriculum 2009] (1Γ—3)

Answer:

Constructor Destructor
Initialises the object Releases resources/cleans up the object
Called automatically when the object is created Called automatically when the object is destroyed
Name: ClassName(); can take arguments and be overloaded Name: ~ClassName(); no arguments, cannot be overloaded

Q35. Write down any three responsibilities of Project Manager. [Annual 2026 – Old Curriculum 2009] (1Γ—3)

Answer:

  • Planning and scheduling: defines project scope, goals, timeline and budget, and divides work into tasks.

  • Team management and coordination: assigns roles, leads and motivates the team, and communicates with clients and stakeholders.

  • Monitoring and control: tracks progress, manages risks, controls cost and quality, and ensures the project is completed on time.

Q36. If p is the pointer variable, what will be the difference between the following statements? [Annual 2026 – Old Curriculum 2009] (03)

cout << p;

cout << *p;

Answer:

  • cout << p; prints the value stored in the pointer, i.e. the memory address of the variable it points to (e.g. 0x61ff08).

  • cout << *p; uses the dereference operator and prints the value stored at that address, i.e. the value of the variable.

  • Example: int x = 25; int *p = &x; Then cout << p shows the address of x, and cout << *p shows 25.

Q37. Write a program to initialize two-dimensional arrays of two different data types. [Annual 2026 – Old Curriculum 2009] (03)

Answer:

#include <iostream>

using namespace std;

int main() {

int marks[2][3] = {{70, 80, 90}, {65, 75, 85}};

char grade[2][3] = {{‘A’, ‘B’, ‘A’}, {‘C’, ‘B’, ‘A’}};

for (int i = 0; i < 2; i++) {

for (int j = 0; j < 3; j++)

cout << marks[i][j] << grade[i][j] << ” “;

cout << endl;

}

return 0;

}

Q38. Write down the output of the following statements: [Annual 2026 – Old Curriculum 2009] (03)

(I) A = (x > 0) && (y < 10) where x = 5, y = 15

(II) S = 13 + 21 % 4

(III) n *= 2; where n = 10

Answer:

  • (I) A = (5 > 0) && (15 < 10) = 1 && 0 = 0 (false)

  • (II) S = 13 + 21 % 4 = 13 + 1 = 14

  • (III) n *= 2 β†’ n = 10 Γ— 2 = 20

Q39. Write down the purpose and syntax of if-else statement. [Annual 2026 – Old Curriculum 2009] (1+2)

Answer:

  • Purpose: the if-else statement executes one block of statements when a condition is true, and another block when it is false (two-way decision).

  • Syntax:

if (condition)

statement(s); // executed if condition is true

else

statement(s); // executed if condition is false

  • e.g. if (marks >= 33) cout << “Pass”; else cout << “Fail”;

Q40. What is the relationship between a class and an object? Discuss briefly. [Annual 2026 – Old Curriculum 2009] (03)

Answer:

  • A class is a blueprint or template that defines the data members (attributes) and member functions (methods) common to all objects of that type. It does not occupy memory for data by itself.

  • An object is an instance of a class. It is a real entity created from the class, with its own values, and memory is allocated for it.

  • Relationship: one class can create many objects. e.g. class Car defines colour, model and speed; car1 (red Honda) and car2 (white Toyota) are objects of Car. (Like a house map and the actual houses built from it.)

Q41. Why is it important to write comments in a program? Also differentiate its two types. [Annual 2026 – Old Curriculum 2009] (03)

Answer:

  • Importance: comments make the program easy to understand, debug, modify and maintain, help other programmers follow the logic, and document the code. They are ignored by the compiler.

  • Single-line comment (//): written on one line, e.g. // input marks

  • **Multi-line comment (/* … */):** extends over several lines, e.g. /* program to calculate grade of student */

Q42. Discuss the concept of inheritance with one daily life example. [Annual 2026 – Old Curriculum 2009]

Answer:

  • Inheritance is an OOP feature in which a new class (derived/child class) acquires the properties and methods of an existing class (base/parent class) and can add its own features. It promotes code reusability and an “is-a” relationship.

  • Daily-life example: a child inherits features from parents (eye colour, surname) and also has their own qualities. In programming: class Vehicle (wheels, speed, start()) β†’ class Car and class Bike inherit these and add their own features, e.g. Car adds airConditioner.

Q43. Write down the output of the following program segment: [Annual 2026 – Old Curriculum 2009] (03)

char c = ‘A’;

do

{

cout << c << “t”;

c = c + 2;

}

while (c <= ‘K’);

Answer:

  • c takes values A, C, E, G, I, K (increasing by 2 while c ≀ ‘K’).

  • Output: A C E G I K

Q44. Write down the output of the following program segment: [Annual 2026 – Old Curriculum 2009] (03)

int x = 5;

do {

cout << x << ” “;

x++;

} while (x < 8);

Answer:

  • x = 5 is printed, then 6, then 7. When x becomes 8, the condition x < 8 is false and the loop stops.

  • Output: 5 6 7

Q45. Rewrite the following statement using if-else statement: [Annual 2026 – Old Curriculum 2009] (03)

cout << (((num % 2) == 0) ? “Evenn” : “Oddn”);

Answer:

if ((num % 2) == 0)

cout << “Evenn”;

else

cout << “Oddn”;

Q46. What is the difference between constant and variable? Give one example. [Annual 2026 – Old Curriculum 2009]

Answer:

  • A constant is a named memory location whose value cannot change during program execution, e.g. const int DAYS = 7;

  • A variable is a named memory location whose value can change, e.g. int count = 0; count = 5;

Q47. What is the purpose of sizeof() function? Illustrate with example. [Annual 2026 – Old Curriculum 2009] (2+1)

Answer:

  • Purpose: sizeof() returns the size in bytes of a data type or variable. It helps in memory management and portability.

  • Example:

char ch; int n; double d;

cout << sizeof(ch) << ” ” << sizeof(n) << ” ” << sizeof(d); // 1 4 8

Q48. What is reference operator? Give an example. [Annual 2026 – Old Curriculum 2009]

Answer:

  • The reference (address-of) operator & gives the memory address of a variable. It is also used to declare reference variables (aliases).

  • Example:

int a = 5;

cout << &a; // address of a

int &r = a; // r is a reference (alias) of a; r = 10 changes a to 10

Q49. Compare local and static variables in terms of scope, lifetime and storage duration. [Annual 2026 – Old Curriculum 2009] (03)

Answer:

Feature Local variable Static variable
Scope Inside the block/function where declared Inside the block/function where declared
Lifetime Until the function ends; recreated on each call Until the program ends; value retained between calls
Storage duration Automatic (stack); not auto-initialised Static (data segment); initialised once to 0 by default

Q50. Write down any three differences between actual and formal parameters. [Annual 2026 – Old Curriculum 2009] (1Γ—3)

Answer:

Actual parameters Formal parameters
Appear in the function call Appear in the function header/definition
Can be constants, variables or expressions Must be variables with data types
e.g. area(5, 3) e.g. int area(int l, int w)

Q51. Rewrite the program segment after removing errors: [Annual 2026 – Old Curriculum 2009] (03)

int a {10}, i;

cout >> “enter ten numbers;

for (i=0; i<10; i–)

cin << a{i};

Answer:

int a[10], i;

cout << “enter ten numbers”;

for (i = 0; i < 10; i++)

cin >> a[i];

  • Corrections: [ ] for array size and index; << with cout; closing quotation mark; >> with cin; i++ instead of i–.

Q52. Write down the difference between multi-tasking and multi-threading. [Annual 2026 – Old Curriculum 2009]

Answer:

Multi-tasking Multi-threading
Running multiple programs (processes) at the same time Running multiple threads of a single program (process) at the same time
Each process has its own memory space Threads share the same memory of the process
More overhead; slower switching Less overhead; faster switching
e.g. using MS Word, a browser and a music player together e.g. a browser loading a page while downloading a file in another tab

Q53. What is real time operating system? Give one example. [Annual 2026 – Old Curriculum 2009] (2+1)

Answer:

  • A real-time operating system (RTOS) processes data and responds to input within a fixed, very short time limit (deadline). Delay can cause failure, so it is used where timing is critical.

  • Example: air-traffic control systems, aircraft autopilot, anti-lock braking (ABS) in cars, medical life-support systems, robots in industry.

Q54. Differentiate between string and array with one example of each. [Annual 2026 – Old Curriculum 2009]

Answer:

String Array
A sequence of characters ending with ‘’ (null character) A collection of elements of the same type (int, float, char)
Example: char city[] = “Lahore”; Example: float price[3] = {10.5, 20.0, 15.5};

Q55. Define a class Student that contains public data members including function get(). [Annual 2026 – Old Curriculum 2009] (03)

Answer:

class Student {

public:

int id;

char name[25];

float gpa;

void get() {

cout << “Enter ID, name and GPA: “;

cin >> id >> name >> gpa;

}

};

Q56. Write down any three advantages of using function overloading. [Annual 2026 – Old Curriculum 2009]

Answer:

  • Improved readability: the same function name is used for similar tasks (e.g. area() for circle, rectangle, triangle), so the code is easier to understand.

  • Code reusability and flexibility: one function name works with different numbers and types of arguments, with no need to remember many different names.

  • Compile-time polymorphism / easier maintenance: the correct version is selected automatically at compile time, which reduces complexity and makes programs easier to modify.

Long Questions with Answers: Unit 8

Q1. Explain the concept of Minimum Viable Product (MVP) and its role in business validation with an example. [Model Paper 2025 (New Curriculum)] (3+2)

Answer:

Concept of MVP

  • A Minimum Viable Product (MVP) is the simplest version of a new product that has only the core (essential) features needed to solve the main problem of early users.

  • It is launched quickly with minimum cost and effort, to test the business idea in the real market and gather feedback before investing heavily in a full product (Build β†’ Measure β†’ Learn).

Role in business validation

  • It validates the riskiest assumptions: do customers really have this problem, and will they use or pay for the solution?

  • Real user data (sign-ups, usage, sales, feedback) shows whether to continue, improve or pivot the idea. This saves time and money and reduces the risk of failure, and can attract investors.

Example

  • Dropbox first released only a short demo video showing how file syncing would work. Thousands of people joined the waiting list, proving demand before the full product was built. (Similarly, a food-delivery start-up may first take orders through a simple WhatsApp number and Google Form before building an app.)

Diagram: Explain the concept of Minimum Viable Product (MVP) and its role in business validation with an example. [Mode

MVP Build–Measure–Learn cycle

Q2. Discuss the primary purpose of a Minimum Viable Product (MVP). How do rapid development and testing contribute to the success of the product? Explain. [Annual 2026 – Paper B] (2+3)

Answer:

Primary purpose of MVP

  • To test and validate a business idea quickly and cheaply with real users, by launching a product with only its core features. It learns what customers really need before investing a lot of time and money in a complete product, reducing the risk of failure.

Contribution of rapid development

  • Faster time to market: the product reaches users early, before competitors, and starts gaining customers and feedback.

  • Low cost and less risk: building only essential features saves resources. If the idea fails, losses are small and the team can quickly pivot.

  • Quick iterations: short development cycles (agile) allow frequent improvements.

Contribution of testing

  • Validates assumptions: usability testing and A/B testing with real users show which features work and whether people will pay.

  • Improves quality and user experience: bugs and design problems are found and fixed early. Feedback guides which features to add, so the final product fits market needs and is more likely to succeed.

Q3. Discuss the primary purpose of a Minimum Viable Product (MVP). How do feature prioritization and scalability contribute to the success of the product? Explain. [Annual 2026 – Paper D] (2+3)

Answer:

Primary purpose of MVP

  • An MVP is the most basic working version of a product with only the essential features. It is launched to validate the idea with real users, gather feedback, and learn about market demand with minimum investment and risk before full development.

Feature prioritisation

  • Only the most important, high-value features that solve the users’ main problem are included (e.g. using the MoSCoW method: Must have, Should have, Could have, Won’t have).

  • This keeps the product simple and lean, avoids feature creep, reduces cost and development time, and focuses testing on what really matters to customers.

  • Example: a ride-hailing MVP includes only booking a ride, live location and fare; extras like a loyalty programme come later.

Scalability

  • The MVP is designed (architecture, cloud hosting, database) so that it can handle growth: more users, data and features without being rebuilt.

  • When the idea is validated and demand rises, the product can expand smoothly, give good performance and support future growth, contributing to long-term success.

Other Topics (Old Curriculum 2009, C++)

Q1. Write a C++ program that displays the following menu: [Model Paper (Old Curriculum 2009)] (05)

Geometry Calculator

1. Display Area of a Circle

2. Display Area of a Rectangle

Enter your choice (1-3):

β€’ If user enters 1, the program should ask for the radius of the circle and then display its area. Use formula: area = Ο€rΒ².

β€’ If user enters 2, the program should ask for the length and width of the rectangle and then display its area. Use formula: area = length Γ— width.

β€’ Display an error message if the user enters a number outside the range of 1 – 3.

Answer:

#include <iostream>

using namespace std;

int main() {

int choice;

float r, l, w, area;

cout << “Geometry Calculatorn”;

cout << “1. Display Area of a Circlen”;

cout << “2. Display Area of a Rectanglen”;

cout << “3. Quitn”;

cout << “Enter your choice (1-3): “;

cin >> choice;

switch (choice) {

case 1:

cout << “Enter radius: “;

cin >> r;

area = 3.14159 * r * r;

cout << “Area of circle = ” << area;

break;

case 2:

cout << “Enter length and width: “;

cin >> l >> w;

area = l * w;

cout << “Area of rectangle = ” << area;

break;

case 3:

cout << “Program ended.”;

break;

default:

cout << “Error: choice must be between 1 and 3.”;

}

return 0;

}

Q2. Write a C++ code that prints sum of the following series: 1Β² + 3Β² + 5Β² + 7Β² + … + 99Β² [Model Paper (Old Curriculum 2009)] (05)

Answer:

#include <iostream>

using namespace std;

int main() {

long sum = 0;

for (int i = 1; i <= 99; i += 2)

sum = sum + i * i;

cout << “Sum = ” << sum;

return 0;

}

  • Output: Sum = 166650

Q3. What is the importance of SDLC? Explain in detail the feasibility and testing phases. [Model Paper (Old Curriculum 2009)] (1+2+2)

Answer:

Importance of SDLC

  • The System Development Life Cycle provides a systematic, step-by-step framework (planning, analysis, design, development, testing, implementation, maintenance) for building information systems. It ensures the system meets user requirements, is completed on time and within budget, has good quality and documentation, and that risks and errors are reduced.

Feasibility phase (study)

  • Checks whether the proposed system is worth developing and practical before investing in it:

  • Technical feasibility: are the required hardware, software and skills available?

  • Economic feasibility: do the benefits exceed the costs (cost–benefit analysis)?

  • Operational feasibility: will users accept and use the system?

  • Schedule and legal feasibility: can it be completed on time and legally?

  • A feasibility report is prepared, and management decides to go ahead, modify or cancel the project.

Testing phase

  • The developed system is tested to find and remove errors and to check that it meets requirements before implementation:

  • Unit testing: individual modules are tested.

  • Integration testing: modules are tested together.

  • System testing: the complete system is tested for performance and security.

  • Acceptance testing (alpha/beta): users test it with real data and approve it.

  • Errors are corrected and testing is repeated until the system is reliable.

Q4. Explain the batch processing and real-time operating systems with one example of each. [Model Paper (Old Curriculum 2009)] (2.5+2.5)

Answer:

Batch processing operating system

  • Jobs with similar requirements are grouped into batches and executed one after another without user interaction. The user submits the job, and output is obtained later.

  • It is efficient for large volumes of repetitive work and makes maximum use of the CPU, but gives no immediate response and debugging is difficult.

  • Example: payroll systems (monthly salary slips), bank statements, utility (electricity) bills.

Real-time operating system (RTOS)

  • Processes data and responds to events within a strict, guaranteed time limit (deadline). A late response is a failure.

  • Hard real-time (deadline must never be missed) and soft real-time (occasional delay acceptable).

  • Example: air-traffic control, aircraft autopilot, ABS braking in cars, medical heart monitors, industrial robots.

Q5. Explain the concept of polymorphism and inheritance with one example of each from daily life. [Model Paper (Old Curriculum 2009)] (2.5+2.5)

Answer:

Polymorphism

  • Polymorphism (“many forms”) is the ability of the same function or operator to behave differently depending on the object or data it acts on (function overloading, overriding, virtual functions).

  • Daily-life example: a person behaves as a teacher in school, a father at home and a customer in a shop: same person, different roles. In programming, a draw() function draws a circle, a rectangle or a triangle depending on the object.

Inheritance

  • Inheritance allows a new (derived/child) class to acquire the properties and methods of an existing (base/parent) class, and add its own. It provides reusability and an “is-a” relationship.

  • Daily-life example: a child inherits features (eye colour, surname) from parents. In programming, class Car and class Bus inherit common features (engine, wheels, start()) from class Vehicle and add their own (Car: AC; Bus: seats for 50).

Q6. Consider the following statements and complete the following table: [Model Paper (Old Curriculum 2009)] (05)

Answer:

Line No. Statement Purpose
1 fstream datafile; Declares an object datafile of class fstream for file input/output
2 datafile.open(“datafile.txt”, ios::in); Opens the file datafile.txt in input (read) mode
3 if (!datafile) Checks whether the file failed to open (does not exist / error)
4 datafile >> ch; Reads data (a character/value) from the file into variable ch
5 datafile.close(); Closes the file and releases it

Q7. Write a program that prints product of three numbers by using default arguments in function. [Model Paper (Old Curriculum 2009)] (05)

Answer:

#include <iostream>

using namespace std;

// default arguments: b and c take default values if not passed

int product(int a, int b = 1, int c = 1) {

return a * b * c;

}

int main() {

cout << “Product(2, 3, 4) = ” << product(2, 3, 4) << endl; // 24

cout << “Product(2, 3) = ” << product(2, 3) << endl; // 6

cout << “Product(5) = ” << product(5) << endl; // 5

return 0;

}

Q8. Write a C++ code that defines a function named Celsius, that takes Celsius temperature as an argument, and returns its equivalent temperature in Fahrenheit. (Use formula: F = 9/5 (C + 32)) [Model Paper (Old Curriculum 2009)] (05)

Answer:

Note: the correct conversion formula is F = (9/5) Γ— C + 32. The printed form, 9/5 (C + 32), contains a misprint.

#include <iostream>

using namespace std;

float Celsius(float c) {

float f = (9.0 / 5.0) * c + 32;

return f;

}

int main() {

float c;

cout << “Enter temperature in Celsius: “;

cin >> c;

cout << “Fahrenheit = ” << Celsius(c);

return 0;

}

  • e.g. input 100 gives Fahrenheit = 212. (9.0/5.0 is used to avoid integer division, which would give 1.)

You can find the other units of 2nd Year Computer Science on the main page: FBISE 2nd Year Computer Science short and long questions, all units.

Questions follow the FBISE HSSC-II Computer Science syllabus and paper pattern. Please confirm all dates and figures on the official website: www.fbise.edu.pk

Need help with 2nd Year Computer Science? Join our live online classes for the Federal Board. Book a free demo class.

All chapters of this subject

πŸ“Œ Struggling with this chapter? Join our live online tuition β€” one-to-one or small group classes with experienced teachers. Book a free demo class β†’

Ask a question about this topic

Your email address will not be published. Required fields are marked *