Free Essay

Pt1420 7 1 Lab

In: Computers and Technology

Submitted By xJrox
Words 298
Pages 2
Unit 7 lab
Short Answer

Module main ()
// Declare variable
Declare String clientName
Declare Real feetUTP=0
Declare Real subtotal=0
Declare Real totalCost=0
Declare String keepgoing=“y”

Display “Do you want to make a call?” Type y for yes.
Input keepgoing
While keepgoing == “y” // Module Calls Call Call Call

End Module

7.2

7.3
// Declare loop control variable
Declare Integer toPower=2
Declare Integer number=2
Declare Integer counter=0
Do
ToPower=number^2 Display “2 to the power of”, number, “is” toPower Counter=counter+1 Number=number+1 While counter < 8
Lab7.4
Declare integer counter = 1
Declare integer toPower = 2
Declare integer number = 2 counter < 7
Display “2 to the power of”, number, “is”, toPower counter = counter + 1
False
toPower = 2 ^ number True Lab7.5
Module Module1
Sub Main()
Dim keepGoing As Integer = 1
Dim Count As Integer = 5 pingMe() openWebsite() finalOutput() While Count > 0
Console.WriteLine("Count down ..." & Count)
Count -= 1
End While
Console.ReadLine()
End Sub
Sub pingMe()
Shell("Ping.exe 127.0.0.1", , True)
End Sub
Sub openWebsite()
Dim myTargetURL As String = "http://www.microsoft.com"
System.Diagnostics.Process.Start(myTargetURL)
End Sub
Sub finalOutput()
Console.WriteLine("Complete and explanation of what this program does.")
Console.WriteLine("The Shell function and ping.exe check for a response from the web server")
Console.WriteLine("Dim is how we declare a variable.")
Console.WriteLine("Press any key to continue...")
Console.ReadLine()
End Sub
End Module

Lab7.6
Module Module1
Sub Main()
Dim Counter As Integer = 0
Dim toPower As Integer = 2
Dim Number As Integer = 2
While Counter < 7 toPower = 2 ^ Number
Console.WriteLine("2 to the power of " & Number & " is " & toPower)
Counter += 1
Number += 1
End While
Console.ReadLine()
End Sub
End Module…...

Similar Documents

Premium Essay

Lab 3 Pt1420

...Lab 3.1 Step 1: Variable Name | Problem (Yes or No) | If Yes, what’s wrong? | Declare Real creditsTaken | No | | Declare Int creditsLeft | Yes | Int should be real | Declare Real studentName | Yes | Real should be string | Constant Real credits needed = 90 | Yes | Credits needed should be one word | Step 2: There is no Set keyword used prior to the equation Should be Set creditsLeft = creditsNeeded - creditsTaken Step 3: The student’s name is Nolan Owens Step 4: This program requires 90 credits and they have taken 20 credits so far. Step 5: 1. //Provide documentation on line 2 of what this program does 2. //This program calculates the credits the student has left before graduation 3. //Declare variables on lines 4, 5, 6, and 7 4. Declare Real creditsTaken 5. Declare Real creditsNeeded 6. Declare Real creditsLeft 7. Declare String studentName 8. //Ask for user input of studentName and creditsTaken on line 9 - 12. 9. Input studentName 10. Input degreeName 11. Input creditsNeeded 12. Input creditsTaken 13. //Calculate remaining credits on line 14 14. Set creditsLeft = creditsNeeded - creditsTaken 15. //Display student name and credits left on line 16 and 17 16. Display “The student’s name is”, studentName 17. Display “This means there are”, creditsLeft, “left until graduation.” Lab 3.2 Lab 3.3 Module Module1 Sub Main() 'local variables used in this program Const......

Words: 275 - Pages: 2

Premium Essay

Lab 7

...IS3445 Security Strategies for Web Applications and Social Networking Lab 7 Assessment 05/10/14 1. How does Skipfish categorize findings in the scan report? As high risk flaws, medium risk flaws, and low issue scans 2. Which tool used in the lab is considered a static analysis tool? Explain what is referred to by static code analysis. RATS, because the running of static code analysis tools that attempt to highlight possible vulnerabilities within ‘static’ (non-running) source code. 3. What possible high risk vulnerabilities did the Rats tool find in the DVWA application source code? Allow system commands to execute. 4. Did the static analysis tool find all the potential security flaws in the application? Yes, although such tools like these would automatically find security flaws with high degree of confidence that what it found was a flaw. 5. What is black box testing on a web site or web application? They’re designed to threat the application as an “unknown entity”; therefore, no knowledge of the tiers is provided. 6. Explain the Skipfish command in detail: ./skipfish-o/var/scans/is308lab.org –A admin:password –d3 –b I –X logout.jsp –r200000 http://www.is308lab.org This is a standard, authenticated scan of a well-designed and self-contained site. 7. During the manual code review, what is noticed about high.php to make it less likely to vicitimize users with XSS reflection and why is it considered more secure? Because when a php is at......

Words: 379 - Pages: 2

Free Essay

Nt1310 Unit 7 Lab 1

...Unit 7 Lab 1 New Building Safety Plan In my safety plan the first things that I’m going to cover are the PPE for working on a construction site where a new building is being placed. First you’re going to need a hard hat so that when anything falls from above, it keeps your brains where they belong like in your head. Second steel toed shoes or boots, preferably boot for a little extra ankle support. But the steel toes to protect your feet from anything being dropped or lowered in case your foot gets in the way. Safety goggles, pretty self-explanatory on this one, just need to keep things out of your eyes! Long pants (blue jeans) protect your legs from different object that could hurt your skin but with pants on you might just get a bruise. Next on the list gloves are always a good idea to wear so that you don’t rip your hands up while you’re working! A water cooler is a must in this situation because it’s going to be hot out and hydration is key to survival! There will also be no running on the job site. Hurry to quickly can cause more accidents than any amount of production you’re getting for running that thirty foot. Only work on the parts of the job that you know, if someone ask for help go ahead and give them a hand but if you’re a plumber then just let the electrician handle his own job. Back to PPE for a sec a back brace would be a good idea to wear also. Once you have a back injury it will be a problem for the rest of your life in most cases. In case of an......

Words: 392 - Pages: 2

Premium Essay

Pt1420 Lab 8

...Lab 8.1 Step 2: The hour is 1 continue loop till the hour is 24 then stop. Step 3: Constant Integer Max_Minutes = 60 Declare Integer minutes For minutes = 1 to Max_Minutes Display “The minute is “, minutes End For Step 4: Constant Integer Max_Seconds = 60 Declare Integer seconds For seconds = 1 to Max_Seconds Display “The second is “, seconds End For Step 6: The number is 2 The number is 4 The number is 6 The number is 8 The number is 10 Step 7: Constant Integer Max_VALUE = 200 Declare Integer counter For counter = 20 to Max_VALUE step 20 Display “The number is “, counter End For Step 9: Enter the number of students in class Display however many numbered students you enter Step 11: Loop five times, each asking you to enter a number Displaying the total at the end Step 12: Declare Integer counter Declare Integer totalAge = 0 Declare Real averageAge = 0 Declare Integer age Declare Integer number Display “How many ages do you want to enter: “ Input number For counter = 1 to number Display “Enter age “ Input age Set totalAge = totalAge + age End For averageAge = totalAge / number Display “The average age is “, averageAge Lab 8.2 Lab 8.3 Module Module1 Sub Main() Dim anotherDay As String = "yes" While anotherDay = "yes" Dim totalSpeed As Double = 0 Dim averageSpeed As Double = 0 enterSpeeds(totalSpeed) calcAverage(totalSpeed, averageSpeed) ...

Words: 324 - Pages: 2

Premium Essay

Pt1420 Unit 7

...Short Answer 1.) Why should you indent the statements in the body of a loop? It visually set them apart from the surrounding code. This makes your program easier to read and debug. 2.) Describe the difference between pretest loops and posttest loops. Pretest loop or do while loop tests its condition before performing iteration whereas a posttest loop or do until loop executes one or more statements and then a condition is tested. 3.) What is a condition- controlled loop? A condition- controlled loop uses a true/ false condition to control the number of times that it repeats. 4.) What is a count- controlled loop? A count- controlled loop repeats a specific number of times. 5.) What three actions do count- controlled loops typically perform using the counter variable? 1. Initialization 2. test 3. increment Algorithm Workbench 1.) Design a While loop that lets the user enter a number. The number should be multiplied by 10, and the result stored in a variable named product. The loop should iterate as long as product contains a value less than 100. //Declare product = 0 do Display “ Enter a number:” Input number product = number x 10 while product <= 100 7.) Convert the While loop in the following code to a Do- While loop: Declare Integer x = 1 While x > 0 Display " Enter a number." Input x End While Declare x as integer = 1 Do Display “ Enter a number:” Input x If x != 0 then Display “ Try......

Words: 606 - Pages: 3

Premium Essay

Lab 7

...Antonio Johnson Class: Access Security Unit: IS3230 September 25, 2014 Lab 2 Design Infrastructure Access Controls for a Network Diagram Lab 2 Answers 1. To check it there I any malware, updates where it be made, and to know if any other viruses are the system or application 2. help to cut down storage and backup cost, to meet legal regulatory requirements for retrieving specific information within a set timeframe. Data strategies are different types and volume. 3. Have backup/ restore for the patch management 4. Networking monitoring allows real-time communication to take place on a data path that’s established and does change. Performances monitoring is circuit-switched networks known for stability and reliability with industry standards, it alarms the network engineers of new attack protocols. It also helps secure IT infrastructure be increasing storage needs 5. I think passwords and PIN are required for multi-factor authentication 6. Systems/Application domain because attackers will target that first. 7. Network-based firewall is a computer network firewall operating at the application layer protocol stack. Hose-based firewall is monitoring any application input, output, or systems services calls are made from. I put in the implementation, the firewall will block out malware and it let me know when the firewall needs to be updated. 8. Consuming Entering Using All 3 controls use permission called authorization which gives users right......

Words: 323 - Pages: 2

Premium Essay

Pt1420 Unit 1

...“Unit 1 Assignment 1” ITT Technical Institute Intro to Programming – PT1420 Unit 1 Assignment 1 Short Answer Questions 1. Why is the CPU the most important component in a computer? The reason the CPU is the most important component in a computer is because without the CPU you can’t run any software. 2. What number does a bit that is turned on represent? What number does a bit that is turned off represent? The number in a bit that represents a turned on position is 1. The number in a bit that represents a turned off position is 0. 3. What would call a device that works with binary data? A digital device is a device that works with binary data. 4. What are the words that make up a high-level programming language called? Keywords or Reserved Words are words that make up a high-level programming language. 5. What are short words that are used in assembly language called? Mnemonics are short words that are used in assembly language. 6. What is the difference between a compiler and an interpreter? The difference between a compiler and an interpreter is that a compiler translates high-level language into separate machine language program while an interpreter translates AND executes the instructions in a high-level language program. 7. What type of software controls the internal operations of the computer’s hardware? An operating system controls the internal operations of the computer’s hardware. Unit 1 Research Assignment 1 * What......

Words: 1534 - Pages: 7

Premium Essay

Lab 7

...Lab #3 – Assessment Worksheet Data Gathering and Footprinting on a Targeted Web Site Course Name and Number: _____________________________________________________ Student Name: ________________________________________________________________ Instructor Name: ______________________________________________________________ Lab Due Date: ________________________________________________________________ Overview The first phase of hacking is the footprinting phase, which is designed to passively gain information about a target. In this lab, you performed technical research against three Web domains using Internet search tools. You collected public domain information about an organization using the Google search engine to uncover information available on the Internet. Finally, you recorded the information you uncovered in a research paper, describing how this information can make an organization vulnerable to hackers. Lab Assessment Questions & Answers 1. What information can you obtain by using the WHOIS tool contained within Sam Spade? 2. Besides the WHOIS utility covered in this lab, what other functions did you discover are possible with the Sam Spade utility? 3. What is the purpose of the tracert command? What useful information does the trace route tool provide? How can this information be used to attack the targeted website? 4. Is Sam Spade an intrusive tool? What is your perspective on the use of a freeware utility such as Sam Spade? 5. By its......

Words: 341 - Pages: 2

Free Essay

Cis 336 Labs 1-7 Complete Course

...336 Labs 1-7 Complete Course http://hwguiders.com/downloads/cis-336-labs-1-7-complete-course/ CIS 336 Labs 1-7 Complete Course http://hwguiders.com/downloads/cis-336-labs-1-7-complete-course/ CIS 336 Labs 1-7 Complete Course http://hwguiders.com/downloads/cis-336-labs-1-7-complete-course/ CIS 336 Labs 1-7 Complete Course http://hwguiders.com/downloads/cis-336-labs-1-7-complete-course/ CIS 336 Labs 1-7 Complete Course http://hwguiders.com/downloads/cis-336-labs-1-7-complete-course/ CIS 336 Labs 1-7 Complete Course http://hwguiders.com/downloads/cis-336-labs-1-7-complete-course/ CIS 336 Labs 1-7 Complete Course http://hwguiders.com/downloads/cis-336-labs-1-7-complete-course/ CIS 336 Labs 1-7 Complete Course http://hwguiders.com/downloads/cis-336-labs-1-7-complete-course/ CIS 336 Labs 1-7 Complete Course http://hwguiders.com/downloads/cis-336-labs-1-7-complete-course/ CIS 336 Labs 1-7 Complete Course http://hwguiders.com/downloads/cis-336-labs-1-7-complete-course/ CIS 336 Labs 1-7 Complete Course http://hwguiders.com/downloads/cis-336-labs-1-7-complete-course/ CIS 336 Labs 1-7 Complete Course http://hwguiders.com/downloads/cis-336-labs-1-7-complete-course/ CIS 336 Labs 1-7 Complete Course http://hwguiders.com/downloads/cis-336-labs-1-7-complete-course/ CIS 336 Labs 1-7 Complete......

Words: 757 - Pages: 4

Free Essay

Pt1420 Lab 7

...Lab 7.1 Module main () Declare String keepGoing = “y” While keepGoing == “y” Declare String clientName = “ “ Declare Real feetUTP = 0 Declare Real subTotal = 0 Declare Real taxCost = 0 Declare Real totalCost = 0 Call inputData (feetUTP, clientName) Call calcCosts (feetUTP, subTotal, taxCost, totalCost) Call displayBill (clientName, totalCost) End While End Module Lab 7.2 Lab 7.3 Module Main() Declare integer toPower = 2 Declare integer number = 2 Declare integer counter = 0 While Counter < 7 Set toPower = 2^Number Display 2 to the power of, “number,” is,”toPower,” Counter += 1 Number += 1 End While End Module Lab 7.4 Lab 7.5 Module Module1 Sub Main() Dim keepGoing As String = "yes" Do While keepGoing = "yes" pingMe() Console.Write("Enter yes if you want to run program again") keepGoing = Console.ReadLine() Loop Console.WriteLine("Press enter to continue. ..") Console.ReadLine() End Sub Sub pingMe() Dim counter As Integer = 5 Do While counter > 0 Console.WriteLine("Count down . ") counter = counter - 1 Loop Console.WriteLine("Now ping. ..") Shell("Ping.exe 127.0.0.1", , True) Console.Out.WriteLine(" ") End Sub End Module Lab 7.6 Module Module1 Sub Main() Dim keepGoing As String = "y" ...

Words: 262 - Pages: 2

Free Essay

Pt1420 Lab 3

...LAB 3.1 Variable Name | Problem (Y or N) | If Yes, what’s wrong? | Declare Real creditsTaken | No | | Declare Int creditsLeft | Yes | The variable should be declared as Real so it can indicate decimal values | Declare Real studentName | Yes | The variable should be a String to store text | Constant Real creditsNeeded = 90 | No | | Step 2: The calculation should be “creditsLeft = creditsNeeded – creditsTaken” Step 3: “The student’s name is Nolan Owens” Step 4: “The Network Systems Administration degree is awarded after 90 credits and Nolan Owens has 70 left to take before graduation.” Step 5: 1. //Provide documentation on line 2 of what this program does 2. //This program calculates how many credits a student still needs to graduate the NSA program 3. //Declare variables on lines 4, 5, 6, and 7 4. Declare Real creditsTaken = 0 5. Declare Real creditsLeft = 0 6. Declare String studentName = “NO VALUE” 7. Declare Constant Real creditsNeeded = 90 8. //Ask for user input of studentName and creditsTaken on line 9 - 12. 9. Display “What is the student’s name?” 10. User input = studentName 11. Display “How many credits does the student have?” 12. User input = creditsTaken 13. //Calculate remaining credits on line 14 14. creditsLeft = creditsNeeded – creditsTaken 15. //Display student name and credits left on line 16 and 17 16. Display “The student’s name is “, studentName 17. Display “They require “,......

Words: 458 - Pages: 2

Premium Essay

Pt1420 1

...Bradley Griffin Keith Warren PT1420 Unit 2 Assignment 1: Homework Short Answer: 1. If the problem is program assignment of some sort, than the first step would be to design the basis of the program in pseudocode to gain a clear picture of what kind of commands will work where, then move into flowcharting to start putting together the logic. b. If the problem is an issue in the code that is preventing it from executing, than the first thing that should be done is to look over the program for syntax errors and logic errors.  2. Pseudocode is fake code. This is where a programmer writes out the code without worry of syntax or logic errors to get a visual feel of how the program should unfold. 3. Input, Process, and Output 4. User-Friendly is a term used to describe programs that are easy to use. Algorithm Workbench: 1. A. Display “Height” B. Input height C. Display “Here is the height you entered:”, height 2. A. Display “Favorite Color” B. Input Favorite Color C. Display “Here is your favorite color you entered:”, color Programming Exercises: 1. Personal Information 1 Display “Name” 2 Input Name 3 Display “Here is the name you have entered:”, name 4 Display “Address with city, state, and ZIP” 5 Input address with city, state, and ZIP 6 Display “This is the address you have entered:”, address with city, state, and ZIP 7 Display “Telephone number” 8 Input telephone number 9 Display “This is the telephone number you have entered:”,......

Words: 277 - Pages: 2

Free Essay

Pt1420 Lab 10

...Lab 10: File Access This lab accompanies Chapter 10 of Starting Out with Programming Logic & Design. Lab 10.1 – File Access and Visual Basic This lab examines how to work with a file by writing Visual Basic code. Read the following programming problem prior to completing the lab. Write and design a simple program that will take 3 pieces of data and write it to a file. Create variables and set them equal to the appropriate values: Declare string firstName = “xxx” Declare string lastName = “xxx” Declare integer age = your age Write this information to a file called myRecords.txt. Next, read this information from the file and print it to the screen. Step 1: Create a new Visual Basic workspace and add the following code: Module Module1 Sub Main() Dim firstName As String = "XXXX" Dim lastName As String = "XXX" Dim age As Integer = #### Dim writer As System.IO.StreamWriter = System.IO.File.CreateText("myRecords.txt") writer.WriteLine(firstName & " " & lastName & " " & age) writer.Close() Dim reader As System.IO.StreamReader = System.IO.File.OpenText("myRecords.txt") Dim myInfo As String = reader.ReadLine() Console.WriteLine(myInfo) reader.Close() 'this causes a pause so you can see your program Console.Write("Press enter to continue...") Console.ReadLine() End Sub End Module Step 2: Change......

Words: 347 - Pages: 2

Free Essay

Lab 7

...Justice Ross Physiology Lab Dr. Xu 2 March 2016 Frog Skeletal Muscle Lab Introduction A biologist by the name Jan Swammerdam performed the first experiments on muscle physiology between 1661 and 1665. Swammerdam demonstrated that an isolated frog muscle can contract if the sciatic nerve is irritated with a metal object. Almost a century later, a physician by the name Luigi Galvani demonstrated that frog muscle responds to electrical currents. In the late 1840s, either Carlo Matteucci or Carl Ludwig attributed to the invention of the kymograph, which is illustrated as a rotating drum powered by a clockwork motor. The invention of the kymograph changed experimental physiology by allowing muscle contractions, and other actions, to be recorded and analyzed for the first time ever. Muscle cells, or muscle fibers, are defined as the basic unit of a muscle. Therefore, complete muscles are constructed from bundles of muscle fibers, but there are no gap junctions between adjacent cells so each fiber performs independently. Myofibrils establish an ordered structure for single muscle fibers. Every myofibril is comprised of actin and myosin. Actin and myosin are contractile proteins that can slide past each other when Ca2+ and ATP are present. A motor unit is described as a single motor neuron and all of its innervating muscle fibers. Like nerve tissue, muscle fibers produce an all-or-none response to a stimulus, generating a twitch. A single motor neuron supplies numerous......

Words: 1350 - Pages: 6

Premium Essay

Unit 7 Lab 1

...Gerald Johnson NT1310T Unit 1 Exercise Local Exchange 3/13/2016 The purpose of a Network is to share data. To make this possible, you have to be able to connect to other computers. To make this enticing to people to want to take advantage of this technology, it has to be simple not so complex. This sounds a little difficult to understand as far as a qualified answer, but to sum things up that is it. The question to ask and that many people don’t consider is how data is transferred from one computer to another computer? Transferring data that is being sent by the user who has created and initialized the transfer of information using a source such as an email service for example. How do you get information from one computer to another, and how do you make it simple and easy to do this? Companies that succeeded at doing this have a great profit with exponential growth possibilities and revenue. For example Cisco company who has made billions by allowing different groups of networks to share data across what we call the internet. Games take advantage of this technology to connect to other computers. Networking companies have succeeded so well in allowing people to connect across their internal networks and the internet that pretty much any app. is able to send data to another computer. There is a physical connection running between two computers that want to connect. This is made possible because phone lines that run from houses to switches to other houses......

Words: 472 - Pages: 2