0% found this document useful (0 votes)
44 views

Unit 12 Assignment 1 Template

This document discusses two simple programs: a maze game program and a languages program. It provides explanations of the purpose, screenshots, characteristics, code, and commenting for each program. The characteristics discussed include programming language, modules and subroutines, variables and data types, mathematical operators, and commenting. The document also discusses reviewing the quality of one of the programs, suggesting improvements and providing a flow chart, as well as discussing the strengths and weaknesses of a program.

Uploaded by

api-674263661
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
44 views

Unit 12 Assignment 1 Template

This document discusses two simple programs: a maze game program and a languages program. It provides explanations of the purpose, screenshots, characteristics, code, and commenting for each program. The characteristics discussed include programming language, modules and subroutines, variables and data types, mathematical operators, and commenting. The document also discusses reviewing the quality of one of the programs, suggesting improvements and providing a flow chart, as well as discussing the strengths and weaknesses of a program.

Uploaded by

api-674263661
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 17

Unit 12 Software Development

Characteristics and uses of software


programs

Dylan Owens
2A.P1) Explain the purpose of two simple
programs and their characteristics,
including tools and techniques used.
Purpose – Maze game
• Explain one purpose of the maze game program
• It’s to be interactive
Screenshots – Maze game program
• Provide a screenshot of program functionality
Public Class Form1
' declare variables
Dim picturearray(7) As PictureBox
Dim x As Integer

Sub Setuppicturearray() 'make array out of picture boxes


For x = 1 To 6 'loop through each picture box
picturearray(x) = New PictureBox
Next
picturearray(1) = PictureBox11
picturearray(2) = PictureBox12
picturearray(3) = PictureBox13
picturearray(4) = PictureBox14
picturearray(5) = PictureBox15
picturearray(6) = PictureBox16

End Sub

Private Sub Form1_Activated(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Activated


Setuppicturearray() 'when form loads up call subroutine to make array
End Sub

Private Sub Form1_KeyDown(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles Me.KeyDown


Dim keycode As Short = e.KeyCode 'find out which key is pressed
Characteristics – Maze game program
• Provide an explanation of the following - Mathematical Operators (What are they?
characteristics: What operators were used and why?)
- Programming language used (Visual Basic) - They move the picture boxes 5 pixels
either – or + they were used
- Module and sub-routines (What are they?)
- Commenting (Why was the code
- Subroutines are blocks of induvial code commented?)
- To make it easier for other to modify code
- Variables and Data Types (What variables were
used? What data types were they? Why were
they used?)

• Dim picturearray(7) As PictureBox


• Dim x As Integer

• To create picture boxes and x as a loop painter


Code and commenting – Maze game program
• Provide a screenshot of code (with commenting)
• Private Sub Form1_KeyDown(ByVal sender As Object, ByVal e As
System.Windows.Forms.KeyEventArgs) Handles Me.KeyDown
• Dim keycode As Short = e.KeyCode 'find out which key is pressed

• If keycode = System.Windows.Forms.Keys.Right Then PictureBox10.Left =


PictureBox10.Left + 5
• If keycode = System.Windows.Forms.Keys.Left Then PictureBox10.Left =
PictureBox10.Left - 5
• If keycode = System.Windows.Forms.Keys.Up Then PictureBox10.Top =
PictureBox10.Top - 5
• If keycode = System.Windows.Forms.Keys.Down Then PictureBox10.Top =
PictureBox10.Top + 5
Purpose - Languages program
• Explain one purpose of the Languages program
The program shows the phrase “hel
Screenshots - Languages program
• Provide a screenshot of program functionality
Characteristics - Languages program
• Provide an explanation of the following characteristics:
- Programming language used (Visual Basic)

- Module and sub-routines (What are they?)

- Subroutines are blocks of induvial code

- Variables and Data Types (What variables were used? What data types were they? Why were they used?)

- No variables in the language program

- Mathematical Operators (What are they? What operators were used and why?)

- Uses ecourse operator

- Commenting (Why was the code commented?)


Code and commenting – Languages program
• Provide a screenshot of code (with commenting)

Private Sub ButtonConvert_Click(sender As Object, e As EventArgs) Handles ButtonConvert.Click


labelDisplay.Text = "Hello World" 'update label text
PictureBox1.Image = My.Resources.union_jack 'update picturebox with flag
ButtonConvert.BackColor = Color.Blue 'change button colour
ButtonConvert.ForeColor = Color.White 'change button text colour

End Sub

Private Sub Button6_Click(sender As Object, e As EventArgs) Handles Button6.Click


Application.Restart() 'restart application to original settings
Me.ShowInTaskbar = False
End Sub

Private Sub Button7_Click(sender As Object, e As EventArgs) Handles Button7.Click


Application.Exit()
End Sub

Private Sub Button3_Click(sender As Object, e As EventArgs) Handles Button3.Click


labelDisplay.Text = "Hola Mundo"
PictureBox1.Image = My.Resources.spain
Button3.BackColor = Color.Yellow 'change button colour
Button3.ForeColor = Color.Red 'change button text colour
End Sub
2A.M1) Comment on the quality of one of the
given simple programs, suggesting any
improvements and provide a flow chart to show
the processing
Quality Review - ??? program
• Comment on the quality of one program
Improvements - ??? program
• Suggest at least three improvements
Flow Chart - ??? program
• Provide screenshot evidence of flow chart
2A.D1) Discuss the strengths and
weaknesses of the software program
Strengths - ??? program
• Discuss at least three strengths of the program (in relation to usability,
functionality, efficiency and/or readability).
Weaknesses - ??? program
• Discuss at least three weaknesses of the program (in relation to
usability, functionality, efficiency and/or readability).
•:

You might also like