• edited by
13,853 views
39 39 votes

The goal of structured programming is to:

  1. have well indented programs
  2. be able to infer the flow of control from the compiled code
  3. be able to infer the flow of control from the program text
  4. avoid the use of GOTO statements

3 Answers

Best answer
66 66 votes

Answer is (C). The goal of structured programming is to able to infer the flow of control from the program text . It means user can execute the code according to his requirement. $C$ and Pascal are good example of structured programming. In structured programming control passes one instruction to another instruction in sequential manner.

Avoiding the use of GOTO statements is not the goal of structured programming, it (avoiding the use of GOTO) is one of the requirements for a program to be structured.

• edited by
20 20 votes

Answer: $C$

The main goal of structured programming is to get an understanding about the flow of control in the given program text. In structure programming various control structures such as switch-case, if-then-else, while, etc. allows a programmer to decode the flow of the program easily

• edited by
1 1 vote

The difference between B and C is that C is more prior than B.

Before compiling the final raw code that is machine dependent, there are various machine independent intermediate representations among which is "SSA" static single assignment.

The SSA works on program's text and do not include any loops. So yes before the actual compiled code, through SSA we can understand the structure and flow of control of our program.

 

A should/must required lecture for understanding SSA: Go classes SSA (Deepak's sir)

Answer:
Position:
Show:

Related questions

39 39 votes
5 answers 5 answers
12.1k
12.1k views
Kathleen asked Sep 18, 2014
12,093 views
Choose the best matching between the programming styles in Group 1 and their characteristics in Group 2.$$\begin{array}{|ll|ll|}\hline \rlap{\textbf{Group 1}} & & \rlap{...
12 12 votes
2 answers 2 answers
7.5k
7.5k views
Ishrat Jahan asked Oct 27, 2014
7,496 views
Match the programming paradigms and languages given in the following table. Paradigms Languages(I)Imperative(a)Prolog(II)Object Oriented(b)Lisp(III)Functional(c)C, Fortra...
60 60 votes
4 answers 4 answers
22.6k
22.6k views
Kathleen asked Sep 18, 2014
22,630 views
Consider the following C program segment:char p[20]; int i; char* s = "string"; int length = strlen(s); for(i = 0; i < length; i++) p[i] = s[length-i]; printf("%s", p);Th...
49 49 votes
4 answers 4 answers
21.6k
21.6k views
Kathleen asked Sep 18, 2014
21,561 views
Consider the following C function:int f(int n) { static int i = 1; if(n >= 5) return n; n = n+i; i++; return f(n); }The value returned by $f(1)$ is:$5$$6$$7$$8$