procedure Mean.
number of marks=0
total=0
Do while You're still got marks
Get mark
Number of Marks=Number of marks+1
Total= Total+mark
End while
Average= total/numbermarks
End
Sunday, 20 March 2011
Wednesday, 16 March 2011
9.1 Program
Visual Basic Code for Program 9.1
Private Sub hsbRed_Scroll (...) Handles hsbRed.Scroll
Me.BackColor = ColorTranslator.FromO1e(RGB(hsbRed.Value, hsbGreen.Value, hsbBlue.Value.))
End Sub
Private Sub hsbGreen_Scroll (...) Handles hsbGreen.Scroll
Me.BackColor = ColorTranslator.FromO1e(RGB(hsbRed.Value, hsbGreen.Value, hsbBlue.Value.))
End Sub
Private Sub hsbBlue_Scroll (...) Handles hsbBlue.Scroll
Me.BackColor = ColorTranslator.FromO1e(RGB(hsbRed.Value, hsbGreen.Value, hsbBlue.Value.))
End Sub
Private Sub hsbBlue_scroll (ByVal sender As System. Object, ByVal e As System.Windows.For (...)
Call ShowFormColour( )
End Sub
Sub ShowFormColour( )
End Class
Me.BackColor = ColorTranslator.FromO1e(RGB(hsbRed.Value, hsbGreen.Value, hsbBlue.Value))
Private Sub hsbRed_Scroll (...) Handles hsbRed.Scroll
Call ShowFormColour( )
End Sub
Private Sub hsbRed_Scroll (...) Handles hsbRed.Scroll
Call ShowFormColour( )
End Sub
Private Sub hsbRed_Scroll (...) Handles hsbRed.Scroll
Call ShowFormColour( )
Private Sub hsbRed_Scroll (...) Handles hsbRed.Scroll
Me.BackColor = ColorTranslator.FromO1e(RGB(hsbRed.Value, hsbGreen.Value, hsbBlue.Value.))
End Sub
Private Sub hsbGreen_Scroll (...) Handles hsbGreen.Scroll
Me.BackColor = ColorTranslator.FromO1e(RGB(hsbRed.Value, hsbGreen.Value, hsbBlue.Value.))
End Sub
Private Sub hsbBlue_Scroll (...) Handles hsbBlue.Scroll
Me.BackColor = ColorTranslator.FromO1e(RGB(hsbRed.Value, hsbGreen.Value, hsbBlue.Value.))
End Sub
Private Sub hsbBlue_scroll (ByVal sender As System. Object, ByVal e As System.Windows.For (...)
Call ShowFormColour( )
End Sub
Sub ShowFormColour( )
End Class
Me.BackColor = ColorTranslator.FromO1e(RGB(hsbRed.Value, hsbGreen.Value, hsbBlue.Value))
Private Sub hsbRed_Scroll (...) Handles hsbRed.Scroll
Call ShowFormColour( )
End Sub
Private Sub hsbRed_Scroll (...) Handles hsbRed.Scroll
Call ShowFormColour( )
End Sub
Private Sub hsbRed_Scroll (...) Handles hsbRed.Scroll
Call ShowFormColour( )
Procedures and functions.
What is a procedure?
A procedure is a seperate section of code which performs one or more specific tasks and is identified by having a name.
Four types:
A procedure is a seperate section of code which performs one or more specific tasks and is identified by having a name.
Four types:
- Event
- Sub
- Function
- Property
Why use procedures?
- Avoid repeating code.
- Make the code more readable
- Help in debugging a program
- Use a procedure in other programs
- Pass parameters.
What is a function?
A procedure could be considered as something which is a set of commands which do not return a value.
Monday, 14 March 2011
Social media.
WIKI, Blogs, RSS and Micro Blog's.
A WIKI is software that runs a wiki or a website that allows users to collaboratively create and edit web pages using a web browser. For example; Wikipedia.
A Blog is a web based mechanism to allow discussion on a topic on the web. For example; Blogger.
A RSS or 'Real simple syndication' is a group of web feed formats used to publish frequently updated sites and topics. For example; Twitter.
A Micro Blog is different from a traditional blog because its content is typically much smaller.
Binary code.
Examples of binary.
For 94
128 . 64 . 32 . 16 . 8 . 4 . 2 . 1
0 1 0 1 1 1 1 0
For the Binary Number 2.5
8 . 4 . 2 . 1 . 1/2 . 1/4 . 1/8
0 0 1 0 1 0 0
0010100 - This Byte is called the mantissa and shows the number with the decimal placed moved to then end.
0000001 - This Byte is called the exponent and shows how many places the decimal place has been moved.
8 bits is usually called a "byte",
and a "nybble" is 4 bits;
For 94
128 . 64 . 32 . 16 . 8 . 4 . 2 . 1
0 1 0 1 1 1 1 0
For the Binary Number 2.5
8 . 4 . 2 . 1 . 1/2 . 1/4 . 1/8
0 0 1 0 1 0 0
0010100 - This Byte is called the mantissa and shows the number with the decimal placed moved to then end.
0000001 - This Byte is called the exponent and shows how many places the decimal place has been moved.
8 bits is usually called a "byte",
and a "nybble" is 4 bits;
Wednesday, 9 March 2011
System processors
Single - user OS a single user OS is a system designed for use on a computer that will allow a single user at a time.
Multi - user OS, simular to the single user OS, the multi user OS allows multiple user to access and operate the system at any given time.
Multi - user OS, simular to the single user OS, the multi user OS allows multiple user to access and operate the system at any given time.
Batch Processing is a technique that uses a single program to process many individual jobs, tasks, or requests.
Revision from test.
Disk formatting zeros the disk. Formats for a particular system. E.g Ntfs
Hardware driver allows a piece of hardware to be used and interact with the computer.
File compression shrinks files. Because you either want to save hardrive space or emailing.
Virus checker uses a registered list of virus of all known virus known around the world which your computer downloads which scans your hardrive of those known files.
Hardware driver allows a piece of hardware to be used and interact with the computer.
File compression shrinks files. Because you either want to save hardrive space or emailing.
Virus checker uses a registered list of virus of all known virus known around the world which your computer downloads which scans your hardrive of those known files.
Tuesday, 8 March 2011
System Software
System Software
- Describe the purpose of operating systems.
- Describe the characteristics of different types of operating systems and their uses: batch, real-time, single-user, multi-user, multi-tasking and network systems
- Identify a range of applications requiring batch processing and a range of applications in which a real time response is required.
- Describe different types of user interface: forms, menus, GUI, natural language and command line, suggesting the characteristics of user interfaces which make them appropriate for use by different types of user.
- Describe the purpose of a range of utility software e.g. disk formatting, file handling, hardware drivers, file compression and virus checkers.
Wednesday, 2 March 2011
Hardware software
everything that happens in a computer goes from
Input-Processor-Output
||
||
Storage
storage
The CPU infact dose not connect directly with the hard drive but instead with the RAM stick. As trying to connect the CPU to hard drive is like talking to someone from a jet plane to a bike.
Software:
Software= sets of instructions which will tell the system how to do something. These instructions are collected together in a workable group which is called a program.
Operating system
Provides a Platform for apps top so on it
Middle, am between apps and hardware e.g Word dose not know anything about printers but OS dose
Translate high level language into machine code
Input-Processor-Output
||
||
Storage
storage
The CPU infact dose not connect directly with the hard drive but instead with the RAM stick. As trying to connect the CPU to hard drive is like talking to someone from a jet plane to a bike.
Software:
Software= sets of instructions which will tell the system how to do something. These instructions are collected together in a workable group which is called a program.
Operating system
- User interface software
Provides a Platform for apps top so on it
Middle, am between apps and hardware e.g Word dose not know anything about printers but OS dose
- Translate software (TS)
Translate high level language into machine code
- Untilities
- Common Applications
Thursday, 17 February 2011
Three types of loops used in Visual Basic 2008
There are three types of loops used in Visual Basic:
For...Next
Do While
Loop...Until
Each performs basically the same function,running a piece of code alot times.
The For...Next loop is used to run a piece of code a set number of times (it is the only loop with a set number of iterations). As its name suggest, it is used when a function needs to be carried out FOR each of several items, for example when doing formatting for each name in a list. The For...Next loop changes a variable every time it runs, so that the function can be specialised for each item.
The Do While loop runs a piece of code if a condition is true. If the loop starts running, here must be a section inside the loop to either alter the condition or break out of the loop, otherwise it will run indefinitely. If the condition is initially false, the Do While loop does not run at all. It could be used instead of a Loop...Until loop nested in an If statement.
The Loop...Until loop is exactly the same as the Do While loop except that it will always run the code inside before checking whether the condition is true; that is, the code inside will always run at least once even if the condition is false.
Loops can be nested inside each other or used in conjunction with control flow statements.
For...Next
Do While
Loop...Until
Each performs basically the same function,running a piece of code alot times.
The For...Next loop is used to run a piece of code a set number of times (it is the only loop with a set number of iterations). As its name suggest, it is used when a function needs to be carried out FOR each of several items, for example when doing formatting for each name in a list. The For...Next loop changes a variable every time it runs, so that the function can be specialised for each item.
The Do While loop runs a piece of code if a condition is true. If the loop starts running, here must be a section inside the loop to either alter the condition or break out of the loop, otherwise it will run indefinitely. If the condition is initially false, the Do While loop does not run at all. It could be used instead of a Loop...Until loop nested in an If statement.
The Loop...Until loop is exactly the same as the Do While loop except that it will always run the code inside before checking whether the condition is true; that is, the code inside will always run at least once even if the condition is false.
Loops can be nested inside each other or used in conjunction with control flow statements.
Wednesday, 16 February 2011
Subscribe to:
Posts (Atom)