create
1. MainMenu form having :
a) button Open Answers File. When button is clicked; open Answer.txt, and read and
store the answers in an array of Strings. Close this file.
b) 2nd button Open Student Responses File. When button is clicked, do following: i. Open StudentResponses.txt file.
ii. Read number of students who sat the exam value and store it a variable.
iii. Then use loop to read student’s responses to questions. This loop runs up to number of students who sat the exam value read in i). For each line read, split record into an Exam Structure array that has an ID and responses field.
c) button titled Open Student Details File. When this button is clicked, do following:
a) Open and read StudentDetails.txt and store data into a StudentDetails structure array.
d) button titled Display Grades Results when clicked, should open up another form titled Grades Results Sheet on which in label should display grades results for class
Code a program that ask a leper to enter the number of rows then it prints the number of rows in pyramids of stars as shown below
*
* * *
* * * *
* * * * *
* * * * * *
how to code :
that a button titled Open Student Responses File. When this button is clicked, do the following: i. Open StudentResponses.txt file. ii. Read the number of students who sat the exam value and store it a variable. iii. Then use a loop to read the student’s responses to the questions. This loop runs up to the number of students who sat the exam value read in i). For each line read, split the record into ID# and responses and store in ID and Responses array or into an Exam Structure array that has an ID and responses field.
how to Create a MainMenu form. On this form implement the following functionality: a) Put a button titled Open Answers File. When this button is clicked; open Answer.txt, and readand store the answers in an array of Strings. Close this file.
1. Rewrite the code below to read each line of a text file into an array named strFordModel.
DoWhile objReader.Peek = -1
strFordModel (intCount) = objReader.Readline( )
intCount + = 1
Loop
The first file contains the answers for the 20 questions and is called Answer.txt. The format of this file is TFTTTTTTFFTFTFTTTTFF.
Each character is a solution for the exam. The first character being the solution for question #1 and the last character the solution for question #20 respectively.
Create a MainMenu form. On this form implement the following functionality: a) Put a button titled Open Answers File. When this button is clicked; open Answer.txt, and read and store the answers in an array of Strings. Close this file
Dim j = 0
While j = 0
j = j - 1
Console.Write(“Hello”)
j = j + 1
End While
Question: If this code is executed, How many times will “Hello” be printed out?
Given three integers j, k and m
Build a function (in any development language) called SeqSummation, that calculates the sequence of summation as per:
j + (j + 1) + (j + 2) + (j + 3) + … + k + (k − 1) + (k − 2) + (k − 3) + … + m
Explanation: increment from j until it equals k, then decrement from k until it equals m.
Function Description
Create the function SeqSummation.
SeqSummation takes the following parameter(s):
• j integer
• k integer
• m integer
Program Output
• the value of the sequence sum
Example
• SeqSummation (5,9,6)
• i = 5, j = 9, k = 6
• Sum all the values from i to j and back to k: 5 + 6 + 7 + 8 + 9 + 8 + 7 + 6 = 56.
• Output: 56
Question
Description: Write a sorting function, that takes in an array of numbers (size n) and outputs the array of numbers as a list, in sorted sequence (highest value to lowest value)
Notes:
• Use any development language you wish
• Do not use any language’s in-built sorting function (example Javascript array.sort). We’re asking you to write the full sorting algorhythm yourself
Example
• simpleSort({1,2,3,4})
Output:
• 4,3,2,1
Question 8b. Bonus: Name the sorting algorhythm
For x = 0 To 100
For y = 5 To -10 step -1
If y = 0 Then
Exit For
End If
Console.Write("Hello")
Next
If x > 10 Then
Exit For
End If
Next
Question: If this code is executed, How many times will “Hello” be printed out?