Pearson eText for Starting Out With Visual Basic -- Instant Access (Pearson+)
8th Edition
ISBN: 9780137506019
Author: Tony Gaddis, Kip Irvine
Publisher: PEARSON+
expand_more
expand_more
format_list_bulleted
Concept explainers
Question
Chapter 4.2, Problem 4.4CP
Program Plan Intro
“If…Then” statement:
- It is the simplest form of control statement in the Visual Basic.
- It is mainly used for decision making and changing the control flow of the
program execution.
Syntax:
Consider the syntax for the “If...Then” statement is as follows:
If condition Then
Statement
End If
Here, the “condition” is a Boolean condition or relational condition and “statement” is an operation or simple or complex statement inside the “If…Then” statement.
Expert Solution & Answer
Want to see the full answer?
Check out a sample textbook solutionStudents have asked these similar questions
Thank u
Add a validation function using Javascript that does the following 2 things:
validates that password entered by the user and reentered password match. Note that minlength ensures it's a minimum of 8 of characters. Test thoroughly!!! Note that usually you would want to check that password meets some minimum requirements such as it includes both upper and lowercase letters and either a number or special character. In Javascript, we use regular expressions to do this. For this assignments, just make sure the password and reentered password match.
validates that the username isn't already taken. Create an array of existing valid usernames. Include Harry, Elizabeth, and Shana.
Using Java
3. Write the framework for a menu-based interface.(a) Declare a boolean variable that will be used to determine if a loop shouldkeep going. Initialize it to true.(b) Display a welcome message with your name.(c) Write a do-while loop that uses the boolean variable as a loop condition. Theremaining steps should all appear in the body of the loop, unless statedotherwise.(d) Display the following menu:Please choose from the following options:1. Addition Quiz2. Multiplication Quiz3. Addition Table4. Multiplication Table5. Exit the program(e) Read an int from the user and store it in a variable.(f) Use that variable as a controlling expression for a switch statement.(g) For cases 1 and 2, output the following and exit the switch statement:Quiz code goes here(h) For cases 3 and 4, output the following and exit the switch statement:Table code goes here(i) For case 5, set the boolean variable to false and exit the switch statement.(j) For the default case output the following and…
Chapter 4 Solutions
Pearson eText for Starting Out With Visual Basic -- Instant Access (Pearson+)
Ch. 4.2 - Prob. 4.1CPCh. 4.2 - In the following If Then statement, assume that...Ch. 4.2 - Do both of the following If Then statements...Ch. 4.2 - Prob. 4.4CPCh. 4.3 - Prob. 4.5CPCh. 4.4 - The following If Then ElseIf statement has...Ch. 4.4 - Prob. 4.7CPCh. 4.6 - Prob. 4.8CPCh. 4.7 - Prob. 4.9CPCh. 4.7 - Prob. 4.10CP
Ch. 4.8 - Convert the following If Then Elself statement...Ch. 4.10 - Prob. 4.12CPCh. 4.10 - Prob. 4.13CPCh. 4.10 - Write a Boolean expression that equals true when a...Ch. 4.10 - Prob. 4.15CPCh. 4.10 - Prob. 4.16CPCh. 4 - A (n) _______structure allows a program to execute...Ch. 4 - A (n) _______operator determines if a specific...Ch. 4 - Boolean expressions can only be evaluated as_____...Ch. 4 - A (n)_______is a Boolean variable that signals...Ch. 4 - Prob. 5FIBCh. 4 - Prob. 6FIBCh. 4 - A(n)________ If statement is an If statement that...Ch. 4 - _______operators connect two or more relational...Ch. 4 - Prob. 9FIBCh. 4 - Prob. 10FIBCh. 4 - Prob. 11FIBCh. 4 - Prob. 12FIBCh. 4 - Prob. 13FIBCh. 4 - Prob. 14FIBCh. 4 - Prob. 15FIBCh. 4 - Prob. 16FIBCh. 4 - Prob. 17FIBCh. 4 - Prob. 18FIBCh. 4 - ________ is the process of inspecting input values...Ch. 4 - Prob. 20FIBCh. 4 - Prob. 21FIBCh. 4 - Prob. 1TFCh. 4 - T F: It is not possible to write Boolean...Ch. 4 - Prob. 3TFCh. 4 - T F: Clicking on a radio button selects it and...Ch. 4 - T F: Radio buttons that are placed inside a group...Ch. 4 - Prob. 6TFCh. 4 - Prob. 7TFCh. 4 - Prob. 8TFCh. 4 - Prob. 9TFCh. 4 - Prob. 10TFCh. 4 - Prob. 1MCCh. 4 - This statement can cause other program statements...Ch. 4 - Prob. 3MCCh. 4 - This statement is like a chain of If statements....Ch. 4 - When placed at the end of an IfThenElself...Ch. 4 - When an If statement is placed inside another If...Ch. 4 - This operator connects two Boolean expressions...Ch. 4 - This operator connects two Boolean expressions...Ch. 4 - Prob. 9MCCh. 4 - This operator connects two Boolean expressions...Ch. 4 - When determining whether a number is inside a...Ch. 4 - When determining whether a number is outside a...Ch. 4 - Prob. 13MCCh. 4 - This method attempts to convert a value to...Ch. 4 - Prob. 15MCCh. 4 - Describe the difference between the If Then ...Ch. 4 - In an IfThenElseIf statement, what is the purpose...Ch. 4 - What is a flag and how does it work?Ch. 4 - Briefly describe how the And operator works.Ch. 4 - Briefly describe how the Or operator works.Ch. 4 - How is the Xor operator different from the Or...Ch. 4 - Prob. 7SACh. 4 - How is the OrElse operator different from the Or...Ch. 4 - Why are the relational operators called...Ch. 4 - Prob. 2WDTCh. 4 - Why does Visual Studio automatically indent them...Ch. 4 - Prob. 4WDTCh. 4 - Prob. 1FTECh. 4 - Prob. 1AWCh. 4 - Write an IfThen statement that assigns 0 to intX...Ch. 4 - Write an IfThen statement that multiplies...Ch. 4 - Prob. 4AWCh. 4 - Write an IfThen statement that sets the variable...Ch. 4 - Write an IfThenElse statement that assigns 1 to...Ch. 4 - The string variable strPeople contains a list of...Ch. 4 - Write an IfThen statement that prints the message...Ch. 4 - Write an IfThen statement that prints the message...Ch. 4 - Prob. 10AWCh. 4 - Prob. 1PCCh. 4 - Roman Numeral Converter The Roman Numeral...Ch. 4 - Fat Percentage Calculator Create an application...Ch. 4 - Weekly Temperatures with Validation Programming...Ch. 4 - Software Sales Software companies often offer...Ch. 4 - Sailboat Race Ranking Programming Challenge 7 in...Ch. 4 - Pay Per Click Advertising Revenue Many Web sites...Ch. 4 - Speed of Sound The following table shows the...Ch. 4 - Prob. 9PCCh. 4 - Name Formatting Create an application that lets...Ch. 4 - Prob. 11PCCh. 4 - Museum Tours Write a program that lets the user...Ch. 4 - Prob. 13PCCh. 4 - Mass and Weight Scientists measure an objects mass...Ch. 4 - Book Club Points Serendipity Booksellers has a...Ch. 4 - Body Mass Index Program Enhancement In Programming...Ch. 4 - Magic Dates The date June 10, 1960, is special...
Knowledge Booster
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.Similar questions
- What happens if the programmer removes the member function getBalance (), and instead substitutes it with sac. getBalance() in conjunction with sac.balance inside the displayBalance instruction? Why? You will need to make the appropriate adjustments to the application so that it can continue to run once these changes have been made.arrow_forwardGive an example of how one of the four ways to control entry could be used. Why should you choose this over the other options in the same field?arrow_forwardThe fingerprint-based voting application can recognize users based on their fingerprint patterns. Since fingerprint authentication is unique for each person, the system can quickly identify the voters using their fingerprints. Naturally, a voter can vote for a candidate only once. The Admin adds all the names and photos of the candidates nominated for the election. The Admin then authenticates users by verifying their identity proof, and after verification, the voter is registered in the system. Furthermore, the Admin even enters the data when the election will end, after which the system will automatically delete the names and photos of the candidates and voters. The users can log in to the system via the unique user ID and password given by the Admin and then use their fingerprints to vote for their preferred candidate. Once the election is over, and the votes are counted, Both the Admin and users can view the election result using the election ID. In the capacity of a System…arrow_forward
- What are the two lines that your program must have in order to be able to call logging.debug()? What line of code can you add to disable all logging messages in your program? Why is using logging messages better than using print() to display the same message? What are the differences between the Step Over, Step In, and Step Out buttons in the debugger? After you click Continue, when will the debugger stop? How do you set a breakpoint on a line of code in Mu?arrow_forwarda class I created a bar code that takes the 1st letter of an event name and the 1st letter of the 1st word and the 2nd word of an event location. In a test class: How would I check for example if HPC1230000 generated bar code matches code generated that was displayed in a menu that listed events. I want to check based on code entered to register people for an event from user input. I also need to check if generated barcode does not match what is entered by user and print "No matching event was found." This is in Javaarrow_forwardGet familiar with access control classes. Compare and analyse the various controls each choice offers.arrow_forward
- can you make it so it reads from the kongcrew.txt file instead of typing out the info? can you also make it where it lists all of the specifications with the information below like the bolded texted in the picture? example below Name Sit Walk Swing ....... and so on with the info below (make one print out before adding the second ss and after so it shows the updated info of how many bananas the monkeys have before and after) the txt file information is below. Donkey Kong Y Y Y N 3 3 1981 Donkey Cranky Kong Y Y N Y 1 0 1985 Donkey Dixie Kong Y Y N Y 2 2 2001 Dixie Kiddy Kong Y N Y N 1 1 2003 Dixie Wrinkly Kong N N Y Y 1 2 1985 Donkey Tiny Kong N N Y Y 2 1 2001 Dixie Diddy Kong Y Y Y N 3 2 1985 Donkey Uncle Kong Y N Y N 1 2 1990 Donkey Chunky Kong N Y Y Y 2 5 2007 Dixiearrow_forwardWe are trying to find out more information about the GET-PROCESS: What cmdlet can we run if we want to access the help file of GET-PROCESS with more than just the basic default information, and it will show which parameter is required. What cmdlet can we run if we want to view the online version of the help file of GET-PROCESS. What cmdlet can we run if we want to find out if there is an Alias for GET-PROCESS. What cmdlet can we run if we want to display a GUI pop up window for GET-PROCESS that allows us to run/copy the cmdlet. Please write down the complete cmdlet with all required parameters and switchparameters.arrow_forwardProgramming in javaarrow_forward
- 1) What is the scenario shown in thediagram ? 2) How many number of messages aresent and received by the Advisor Object ? 3) What happens when student not approve? 4) How many number of synchronous messages are shown ? 5)How many number of asynchronous messages are shown ? 6)How many number of self messages are shown ? 7)How many number of reply messages are shown ? 8) What is happening in Loop frame?arrow_forwardImplement the "Replace player" menu option. Prompt the user for the jersey number of the player to replace. If the player is in the roster, then prompt again for a new jersey number and rating. Update the replaced player's jersey number and rating.Ex: Enter a jersey number: 4 Enter a new jersey number: 12 Enter a rating for the new player: 8arrow_forward“Reverse - engineer” the code to produce an Object Diagram for the Producer and the Consumer classes found in the lower portion of the code. (Ignore the CandP class, it is just the staging for the application.) Using your common sense describe how you could improve the efficiency of this process in a few sentences.arrow_forward
arrow_back_ios
SEE MORE QUESTIONS
arrow_forward_ios
Recommended textbooks for you
- Database System ConceptsComputer ScienceISBN:9780078022159Author:Abraham Silberschatz Professor, Henry F. Korth, S. SudarshanPublisher:McGraw-Hill EducationStarting Out with Python (4th Edition)Computer ScienceISBN:9780134444321Author:Tony GaddisPublisher:PEARSONDigital Fundamentals (11th Edition)Computer ScienceISBN:9780132737968Author:Thomas L. FloydPublisher:PEARSON
- C How to Program (8th Edition)Computer ScienceISBN:9780133976892Author:Paul J. Deitel, Harvey DeitelPublisher:PEARSONDatabase Systems: Design, Implementation, & Manag...Computer ScienceISBN:9781337627900Author:Carlos Coronel, Steven MorrisPublisher:Cengage LearningProgrammable Logic ControllersComputer ScienceISBN:9780073373843Author:Frank D. PetruzellaPublisher:McGraw-Hill Education
Database System Concepts
Computer Science
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:McGraw-Hill Education
Starting Out with Python (4th Edition)
Computer Science
ISBN:9780134444321
Author:Tony Gaddis
Publisher:PEARSON
Digital Fundamentals (11th Edition)
Computer Science
ISBN:9780132737968
Author:Thomas L. Floyd
Publisher:PEARSON
C How to Program (8th Edition)
Computer Science
ISBN:9780133976892
Author:Paul J. Deitel, Harvey Deitel
Publisher:PEARSON
Database Systems: Design, Implementation, & Manag...
Computer Science
ISBN:9781337627900
Author:Carlos Coronel, Steven Morris
Publisher:Cengage Learning
Programmable Logic Controllers
Computer Science
ISBN:9780073373843
Author:Frank D. Petruzella
Publisher:McGraw-Hill Education