IT Pseudocode SBA
IT Pseudocode SBA
Start
Begin
Print “Enter candidate name for “ , Party [ K ]
Accept name [ K ]
Print “Enter votes received by” , name [ K ]
Accept votes [ K ]
(*Calculating the numbers of votes in each constituency & voter turnout*)
Total_votes [ J ] = total_votes [ J ] + Votes [ K ]
Perc_votes [ J ]= total_votes [ J ] / NRV [ J ] * 100
(*finding details for winning candidates*)
If votes [ K ] > highest_votes [ J ] then
Begin
Highest_votes [ J ]= votes [ K ]
Highest_name [ J ]= name [ K ]
Highest_party [ J ]= party [ K ]
End if
(*finding the amount of candidates in each constituency*)
Cand_no [ J ] =number
End if
ENDFOR
ENDFOR
For L = 1 to 10 DO
Begin
Print cand_no [ L ]
Print total_votes [ L ]
Print perc_votes [ L ]
Print highest_votes [ L ]
Print highest_name [ L ]
Print highest_party [ L ]
EndFOR
Stop.