0% found this document useful (0 votes)
89 views4 pages

XM Comp Sci - Ch-1 S-Q All

The document discusses problem solving and programming concepts. It defines key terms like problem, program, algorithm and flowchart. It also explains the importance of identifying problems, specifying requirements, analyzing problems and designing algorithms and flowcharts. The document contains questions and answers on these topics.

Uploaded by

Zamir
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
89 views4 pages

XM Comp Sci - Ch-1 S-Q All

The document discusses problem solving and programming concepts. It defines key terms like problem, program, algorithm and flowchart. It also explains the importance of identifying problems, specifying requirements, analyzing problems and designing algorithms and flowcharts. The document contains questions and answers on these topics.

Uploaded by

Zamir
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

Chapter # 1:

Problem Solving

Q.1. What is meant by problem solving?


Problem solving is a process of identifying a problem and finding the best solution for it. It is a skill that can be
developed by following a well-organized approach. Every problem is different in its nature. Different solutions
of a problem are identified and the best solution is selected.
Q.2. Define programming.
Programming is a process of solving a problem with the help of computer system. It prepares different
instructions for computer
Q.3. Can a person be a good programmer if he is expert in problem solving?
Programming is a problem solving activity performed with the help of computer system. A programmer write
instructions in programming language and computer executes these instruction to solve a problem. A person can
be a good programmer if he is expert in problem solving.
Q.4. Define program.
A set of instructions given to the computer to solve !l problem is called program. A computer works according to
the instructions written in program.
Q.5. Why is it important to identify a problem?
Problem identification is an important step to find the correct solution of a problem. A problem cannot be solved
if it is not identified correctly. In this stage, the problem is observed carefully and major areas of concern are
identified. Their relevant information is removed in this step:
Q.6. Why is it important to specify requirements to solve a problem?
The requirement specification is a very important step to solve a problem. The user requirements are specified
clearly in this stage so that a prop.;!r solution can be suggested. A requirements document is prepared that
describes the expected features of the system, It contains the details of the system that' will be designed and used.
Q.7. Will there be any problem if the requirements are not specified to solve a problem?
It is not possible to find the correct solution of a problem if the requirements are not specified clearly. Many
users cannot explain the exact requirements of the software. The confusing requirements in the mind of user may
lead to a wrong solution.
Q.8. Define the. Process of analyzing a problem.
Analyzing problem is a process of understanding the problem. The analysis of problem is very important step to
solve any problem. A problem cannot be solved without understanding it correctly.
Q.9. What is the importance of analyzing a problem?
The process of analyzing a problem is very important In this step, a problem is divided into smaller parts. The
smaller parts are solved independently. The process of problem solving becomes simpler and easier with this
method.
Q.l0. What is top down design?
The technique of dividing a problem in small parts is called top down design. It is also called divided and conquer
rule,
Q.11. What method should be adopted to solve complex problems?
The top down method should be adopted to solve complex problems. This method divides a complex problem in
small parts that can be solved easily.
Q.12. Why is an algorithm designed to solve a problem?
The designing of algorithm requires a list of steps required to solve a problem. It is then verified whether the
algorithm solves the problems according to the requirement or not. The process of problem solving becomes
simpler and easier with the help of algorithm.
Q.13. Why is flowchart designed to solve a problem?
A flowchart is designed after the designing of algorithm. Flowchart is a graphical representation of an algorithm.

It helps to understand the algorithm easily. It is also helpful in understanding the flow of control and data in
algorithm.
Q.14. How is desk checking performed?
Desk checking is used to verify the. accuracy of an algorithm. In this process, each step of algorithm is
performed on the paper. Different values are given as input and the output is checked.
Q.l5. What happens in the process of writing program?
In this step, an algorithm is converted into a program. The program consists of different steps . given in the
algorithm. The problem is solved when the computer executes the program.
Q.16 .. What is syntax of a programming language?
A set of rules of a programming language is known as syntax: A program must be written according to the
syntax of a programming language.
Q.17. Why should the programmer know the syntax of programming language to solve a
problem on computer?
A programmer selects a programming language whose syntax is known to him. He cannot write a program if he
does not know the syntax. The problem cannot be solved on computer.
Q.18. Write down any two skills of a good programmer.
Two skills of a good programmer include problem solving skill and programming.
Q.19. Differentiate between bug and debugging.
An error in program is called bug. The process of finding and removing errors in program is called debugging.
The programmer can make different errors while writing programs.
Q.20. Write different types of errors in the program.
Different types of errors in the program include syntax errors, logical errors and run-time errors.
Q.21. Why is it necessary to test a program?
It is necessary to test a program to verify its accuracy. The program is tested by executing it again and again. All
bugs in the program are detected and removed during program testing. It ensures that the program gives desired
results and the problem is solved correctly.
Q.22. When does a syntax error occur?
A syntax occurs when an instruction is not written according to the rules of the programming language.
Q.23. Write some causes of syntax errors.
One cause of syntax error is typing a misspelled command in the program such as PRENT . instead of, PRINT.
Another cause is trying to assign a value to a constant such as 5 - X.
Q.24. What is logical error?
A type of error that occurs due to poor logic of programmer is called logical error. A statement with-logical error
may produce unexpected and wrong results in program.
Q.25.Give some causes of logical errors.
One cause of logical error is using wrong conditions in program such as writing a < 5 instead of a> 5. Another
cause is using wrong formula in the program such as writing Average = Total * 5 instead of Average = Total /5.
Q.26. How can a logical error be found in a program?
A logical error can be found in a program by testing the program instructions thoroughly, checking all variables
closely and. testing all logical flows in the program.
Q.27. How is runtime error found?
A runtime error is found during the execution of program. It occurs when statement directs the computer to
execute an illegal or undefined operation.
Q.28 Give some causes or run-rime errors.
One cause of run-time error is dividing a number by zero. Another cause is opening a file that does not exist.

Q.29. Differentiate between run-time errors and logical errors.


A type of error that occurs during the execution of program is called run-time error. It occurs when. a statement
directs the computer to execute an illegal or undefined operation. A type of error that occurs due to poor logic of
programmer is called logical error. Logical error is difficult to find as .compared to run-time error.
Q.30. What type of error occurs by following a wrong algorithm?
A logical error occurs by following a wrong algorithm.
Q.31. Why logical errors are the most difficult errors?
The logical errors are the most difficult because they cannot be detected by the compiler. They do not crash the
program. That is why they are difficult to detect. The user needs to review the whole program to find out logical
error.
Q.32. Why a program should be maintained and updated?
A program should be maintained and updated continuously. It includes the upgrading of the program to meet
new requirements of hardware and software. The program is modified if there is any change in user
requirements. The continuous usefulness of a program depends on regular maintenance.
Q.33. Why documentation is considered vital in problem solving process?
Documentation is very vital in problem solving process. It helps user to operate and understand program easily. It
also describes how input data is identified in program and how output is formatted. It provides instructions to
install program and requirement of operating system and hardware.
Q.34. Define an algorithm.
An algorithm is a step-by-step procedure to solve a problem. It is better to write algorithm before writing the
actual computer program.
Q.35. What do you mean by refining an algorithm?
The process of refining an algorithm means that the algorithm is made simpler and easier to understand.
Q.36. Is it necessary for an algorithm to solve problem in finite number of steps? If yes, why?
Yes, it is necessary for an algorithm to solve problem in finite number of steps. The reason is that the solution of
any problem may not consist of infinite steps. The algorithm has a clear start and end. The solution is found when
all steps of algorithm are performed in a sequence from start to end
Q.37. Define flowchart.
Flowchart is a graphical representation of an algorithm. It is a way of visually presenting the flow .of data, the
operations performed on data and the sequence of these operations. A programmer prefers to design the
flowchart before writing the computer program.
Q.38. What is the importance of flowcharts for writing computer program?
Flowchart is important for writing computer program because it helps to understand the logic of problem solving
process. The program can be written easily in any programming language after flowchart has been designed. The
programmer can easily follow the steps of flowchart.
Q.39. Write any three guidelines for flowcharting.
Flowchart should be clear, neat and easy to follow. The flow of a flowchart can be from left to right or top to
bottom. Only one flow line should enter and come out of the process symbol.
Q.40. Write two advantages of flowchart.
The advantage of flowchart is that it acts like a guide for program development It also helps in debugging
process.
Q.41. Write two limitations of flowchart.
The limitation of flowchart is that it is difficult to draw flowcharts for complex problems. It has to be redesigned
if any change is required.
Q.42. Differentiate between flowchart and algorithm.
Flowchart consists of standard symbols but algorithm- consists of simple English. Flowchart is more

time-consuming but algorithm is less' time-consuming. Flowchart is difficult to modify but algorithm is easier to
modify.
Q.43. For what purpose rectangle symbol is used?
Rectangle is used to represent a processing or computational operation in the flowchart.
Q.44 Draw process symbol and write it use in flowchart.
The process symbol is used to represent a processing or computational operation in the flowchart.
Q45. Which symbol is used to start and end the flowchart?
The oval symbol is used to start and end the flowchart It is also called terminal symbol.

You might also like