2) A BMI Calculator: the body mass index (BMI) is a measure used to determine whether a person is overweight or not. We can calculate BMI from the weight of the person (in pounds) and the height (in inches) of the person. The formula for calculating BMI is: BMI = (weightInPounds 703) divided by (heightInInches squared) In this problem, you will have to create a BMI calculator, i.e., a Java program, that reads the user's weight in pounds and height in inches, then calculates and displays the user's body mass index BMI. Also, display the following information from the US Department of Health) so the user can evaluate his/her BMI: BMI values: Underweight: less than 18.5 Normal: between 18.5 and 24.9 Overweight: between 25 and 29.9 Obese: 30 or greater
Q: J 2 Indicate whether the following statements are True or false. Justify the reasoning and provide a…
A: The question has been answered in step2
Q: Data is represented in computer memory as a. characters and numbers b. symbols c. ones and zeros d.…
A: All questions are answered below:
Q: b. Given 1st = [30, 1, 12, 14, 10, 0], how many elements are in 1st? What is the index of the first…
A: “Since you have posted a question with multiple sub-parts, we will solve first three sub-parts for…
Q: Cloud computing has many advantages over traditional computing. One of the primary advantages of…
A: Cloud computing is a needs-based delivery of computer system resources, especially data storage and…
Q: eds to allocate addresses for two organiza th 500 addresses, two organizations each dresses and…
A: Here, Given an ISP address of 80.70.56.0/21, the prefix length is 21.
Q: one of Amoeba OS, Banyan-vires OS and CentOS world-class operating systems, for its operations. None…
A: Please check the step 2 for solution
Q: I am having an error in the following java method. pipeline <- javaMethod('createCoreNLP',…
A: Sys.setenv(JAVA_HOME='C:\\Program Files\\Java\\jdk-18.0.1.1')library(rJava) library(coreNLP)options(…
Q: Write a program that takes an integer as an input and returns whether it is a prime number or not.
A: Q. Write a program that takes an integer as an input and returns whether it is a prime number or…
Q: What is Onion network?
A: Onion network or in other words we can say that is short form of TOR ( The Onion Routing ) is an…
Q: Consider the function definition below. Assume x = 5, y = void findout (int &x, int y, int &j) { }…
A: Let us see the answer below.
Q: Path MTU is the smallest MTU of any link on the current path (route) between two hosts. Assume we…
A: The question has been answered in step2
Q: non-volatile da inning Windows
A: Volatile data: Volatile data is the data that is typically put away in reserve memory or RAM. This…
Q: 6. Refer the table below: Table 1: Process arrival/CPU-burst times and priorities. Process Arrival…
A:
Q: Perform the Bubble Sort on the following list. You can use the sample algorithm presented during…
A: Introduction Bubble sort is one of the sorting techniques that work on the logic of repeatedly…
Q: Define in briefbthe impact digital technology has had on assistive devices for people with physical…
A: Assistive technology is the advances that make life simple for individuals who have actual…
Q: signal.. Each time slot contains 148 bits. Just 114 of these 148 bits reflect speech or other info.…
A: The answer is
Q: 7. Write a function that evaluates the area of a pentagon. Use "math.pi", for pi, and "math.sqrt"…
A: code snippet:
Q: nd the smallest Max ] is in the receive wi e. nowing that MaxSec
A: 1) The smallest working value for MaxSeqNum is 8 It suffices to show that if DATA[8] is in the…
Q: for a switching network. Calculate the total data times needed when the following switching techn…
A: The answer is
Q: I keep getting the following error: Traceback (most recent call last): File "main.py", line 2, in…
A: Given Python program is, phone_number = int(input("Enter your 10-digit phone number: "))line_number…
Q: Show that the Internet checksum will never be 0xFFFF (that is, the final value of sum will not be…
A: As per the definitions from the RFC 1624:
Q: “Supporting a travel agency, TORS maintains tour information and provides reservation facilities for…
A: Here we have given specifications in the fully dressed form for the use case diagram. you can find…
Q: Tell me about AWS glue
A: The above question is solved in step 2 :-
Q: Mbps Ethernet with a delay of 1 Mbps Ethernet with a single sto hat of Exercise 16(b), packet siz…
A: (a) 10 * 10^6 bits/sec * (10*10^-6 sec) = 100 bits = 12.5 bytes (b) The first-bit delay is 1020…
Q: Path MTU is the smallest MTU of any link on the current path (route) between two hosts. Assume we…
A:
Q: Suppose you are designing a sliding window protocol for a 1-Mbps point-to-point link to the…
A: Two typical settings are : If, RWS = 1, which recommends that the beneficiary won't uphold any.…
Q: Which is a for broadcast monitoring form of Commercial Online Information ?
A: The question has been answered in step2
Q: Suppose a 10-Mbps Ethernet hub (repeater) is replaced by a 10-Mbps switch, in an environment where…
A: Given that, In a network, 10-Mbps Ethernet hub (Repeater) is replaced by a 10-Mbps switch. The…
Q: Create a AWS glue job and write python program to print sum of two numbers in AWS glue in AWS…
A: aws glue create-job --name python-job-cli --role Glue_DefaultRole --command '{"Name" :…
Q: and individual networks. This can be achieved by dividing the 32-bit IP addresses into two parts: an…
A: The answer is
Q: . Let A and B be two stations attempting to transmit on an Ethernet. Each has a steady queue of…
A: Ethernet:- Ethernet is a method to interconnect multiple computers in a small area, this is one of…
Q: Suppose a host has a 1-MB file that is to be sent to another host. The file takes 1 second of CPU…
A:
Q: Suppose the round-trip propagation delay for Ethernet is 46.4 µs. This yields a minimum packet size…
A: The answer is written in step 2
Q: What is a firewall's principal purpose? What are the general guidelines for using packet filtering?
A: The above question that is what is firewall's principal purpose and what are the general guidelines…
Q: Why was net neutrality repealed?
A: The question has been answered in step2
Q: In a Python program, how do you convert data entered at the keyboard into a whole number? a. Just…
A: Dear Student, When we take input in python its in string (str) format to convert it to whole numbers…
Q: Suppose you are designing a sliding window protocol for a 1-Mbps point-to-point link to the…
A: Introduction Two normal settings are : In the event that, RWS = 1, which suggests that the…
Q: 6 Let A = (1, 2, 3, 4), B = {4, 5) Find the Cartesian Product A x B *
A:
Q: Do it in intelij IDE other wise will give down vote Write python program to give whether a number…
A: Here I have created a function named checkIsPrime(). Inside the function, I have used a conditional…
Q: In C program. implement list_find( list_t* list, int targetElement ) function /* * dataStructure.h *…
A: The answer is given below.
Q: Give some details of how you might augment the protocol with flow control by having ACKS carry…
A: We assume ACKs carry an additional variable k, which indicates the available buffer space of the…
Q: until now, we have not puts should follow a p fines and calls a text va
A: Solution: text_validator.py def text_validator(): """ function to validate full name """…
Q: and a bandwidth of 12000 KHz. What is the
A: The answer is
Q: Consider a simple protocol for transferring files over a link. After some initial negotiation, A…
A:
Q: index=0 for 1 to 20 //get user input value into array arr[index]=input index-index +1 //calculate…
A: C++ program for ( 2a. ) #include<iostream> using namespace std; //2a. complete c++ program…
Q: Suppose that we run the sliding window algorithm with SWS = 5 and RWS = 3, and no out-of-order…
A: Assume we employ the sliding window technique with SWS = 5 and RWS = 3. When we want a dependable…
Q: Consider this 2-D array named a: int [][] a = { }; { 47, 56, 77 }, ( 56, 77, 47 }, {77, 47, 56 }…
A: Q. Consider this 2-D array named a: int [][] a = { { 47, 56, 77 }, { 56, 77, 47 }, { 77, 47, 56 } };…
Q: 1. In each row, four items are given: function to which runtime is proportional, original input…
A: 1. logn : New input = n^2 , so new runtime will be twice of 2*old time (as log(n^2) = 2 log(n)) = 8…
Q: > Let L = {a"b":n>0} a. Show that L² is a context-free language. b. Show that L' is a context-free…
A: Context free language is the language that is generated by the context free grammar or according to…
Q: What controls do you think could be implemented to protect a system from users keeping covert data…
A: Question 1 1. First, and most importantly, the bad guys can't use alternate data streams to do their…
Step by step
Solved in 2 steps
- Problem Description: In the Whimsical Library, each book is enchanted with a magical code to ensure the protection of knowledge. The validation process for these magical codes involves a combination of mathematical spells. The validation process is described as follows: Take the sum of the digits at odd positions from left to right. Take the sum of the squared digits at even positions from left to right. If the absolute difference between the results from step 1 and step 2 is a prime number, the book code is considered valid; otherwise, it is invalid. Example 1: Consider the magical book code 86420137. Step 1. Take the sum of the digits at odd positions from left to right. 8+4+0+3=15 Step 2. Take the sum of the squared digits at even positions from left to right. 6^2+2^2+1^2+7^2=36+4+1+49 = 90 Step 3. If the absolute difference between the results from step 1 and step 2 is a prime number. 115-901 75 (not a prime number) Book code 86420137 is invalid. Example 2: Now, let's examine the…In Saudi Arabia, the Kudai Parking Area is a parking lot that is next to the Ajyad Police Station and close to the Power Plant. Kudai is a well-known parking space near Masjid al-Haram. After parking there, you can take a taxi to Masjid al-Haram for 10-15 Riyals for a 10-minute drive. The parking is usually heavily occupied, and the following formula is used to compute the parking lot uțilization: Percentage of Parking Lot Utilized - Number of lots occupied + Total number of lots Write a program that calculates the occupancy rate for each zone of a massive parking lot like Kudai. The program should start by asking for the number of zones in the parking lot. A loop should then iterate once for each zone. During each iteration, the loop should ask the user for the number of lots in the zone and the number of them that are occupied. After all the iterations, the program should display the number of lots the parking has, the number of them that are occupied, the number that is vacant, and…When you borrow money to buy a house, a car, or for some other purpose, you repay the loan by making periodic payments over a certain period of time. Of course, the lending company will charge interest on the loan. Every periodic payment consists of the interest on the loan and the payment toward the principal amount. To be specific, suppose that you borrow $1,000 at an interest rate of 7.2% per year and the payments are monthly. Suppose that your monthly payment is $25. Now, the interest is 7.2% per year and the payments are monthly, so the interest rate per month is 7.2/12 = 0.6%. The first months interest on $1,000 is 1000 0.006 = 6. Because the payment is $25 and the interest for the first month is $6, the payment toward the principal amount is 25 6 = 19. This means after making the first payment, the loan amount is 1,000 19 = 981. For the second payment, the interest is calculated on $981. So the interest for the second month is 981 0.006 = 5.886, that is, approximately $5.89. This implies that the payment toward the principal is 25 5.89 = 19.11 and the remaining balance after the second payment is 981 19.11 = 961.89. This process is repeated until the loan is paid. Write a program that accepts as input the loan amount, the interest rate per year, and the monthly payment. (Enter the interest rate as a percentage. For example, if the interest rate is 7.2% per year, then enter 7.2.) The program then outputs the number of months it would take to repay the loan. (Note that if the monthly payment is less than the first months interest, then after each payment, the loan amount will increase. In this case, the program must warn the borrower that the monthly payment is too low, and with this monthly payment, the loan amount could not be repaid.)
- (Data processing) Your professor has asked you to write a C++ program that determines grades at the end of the semester. For each student, identified by an integer number between 1 and 60, four exam grades must be kept, and two final grade averages must be computed. The first grade average is simply the average of all four grades. The second grade average is computed by weighting the four grades as follows: The first grade gets a weight of 0.2, the second grade gets a weight of 0.3, the third grade gets a weight of 0.3, and the fourth grade gets a weight of 0.2. That is, the final grade is computed as follows: 0.2grade1+0.3grade2+0.3grade3+0.2grade4 Using this information, construct a 60-by-7 two-dimensional array, in which the first column is used for the student number, the next four columns for the grades, and the last two columns for the computed final grades. The program’s output should be a display of the data in the completed array. For testing purposes, the professor has provided the following data:Brute force equation solver this is python program. Numerous engineering and scientific applications require finding solutions to a set of equations. Ex: 8x + 7y = 38 and 3x - 5y = -1 have a solution x = 3, y = 2. Given integer coefficients of two linear equations with variables x and y, use brute force to find an integer solution for x and y in the range -10 to 10. Ex: If the input is: 8 7 38 3 -5 -1 Then the output is: 3 2 Use this brute force approach: For every value of x from -10 to 10 For every value of y from -10 to 10 Check if the current x and y satisfy both equations. If so, output the solution, and finish. Ex: If no solution is found, output: No solution You can assume the two equations have no more than one solution. Note: Elegant mathematical techniques exist to solve such linear equations. However, for other kinds of equations or situations, brute force can be handy. ''' Read in first equation, ax + by = c '''a = int(input())b = int(input())c = int(input()) ''' Read in…Scenario As you surely know, due to some astronomical reasons, years may be leap or common. The former are 366 days long, while the latter are 365 days long. Since the introduction of the Gregorian calendar (in 1582), the following rule is used to determine the kind of year: if the year number isn't divisible by four, it's a common year, otherwise, if the year number isn't divisible by 100, it's a leap year. otherwise, if the year number isn't divisible by 400, it's a common year. otherwise, it's a leap year. none of the above year int(input("enter the year")) if (year%4 1-0) and (year%400 -0) or (year % 1000): print (year is common year") else: print(year, is leap year") year= int(input ("enter the year")) if (years !-0) or (year480 1-0) and (year % 1001-0): print(year is common year") else: print(year, "is leap year") D year= int(input("enter the year"))
- You may only use 'not' and 'or' to solve this along with parenthesesProblem Descriptions: In this problem, your task is to write a program to find whether a user-entered 2-D point (P) lies (i) (ii) (iii) The circles are specified using their center coordinates and radii. See the illustrations below showing all three cases you need to consider: within both of the two given circles, within only one of those circles, or outside both circles (treat a point ON a circle as being inside the circle). Pis outside both circles Pis inside ONLY one circle Sample Outputs: Sample output #1 POINT MEMBERSHIP WITHIN TWO CIRCLES Circle 1: center at ( 6, -5 ) and radius: 3 Circle 2: center at ( 12, -7 ) and radius: 5 Please enter the x-coordinate of the test point: 8 -5 Please enter the y-coordinate of the test point: Point lies within both circles. Sample output #2 POINT MEMBERSHIP WITHIN TWO CIRCLES Circle 1: center at ( 6 , -5 ) and radius: 3 Circle 2: center at ( 12 , -7 ) and radius: 5 Please enter the x-coordinate of the test point: 12 Please enter the y-coordinate…Summary Interest on a credit card's unpaid balance is calculated using the average daily balance. Suppose that netBalance is the balance shown in the bill, payment is the payment made, d1 is the number of days in the billing cycle, and d2 is the number of days payment is made before billing cycle. Then, the average daily balance is: averageDailyBalance = (netBalance * d1 payme If the interest rate per month is, say, 0.0152, then the interest on the unpaid balance is: interest averageDailyBalance * 0.0152 Instructions Write a program that accepts as input netBalance, d1, payment, d2, and interest rate per month ( interestRate).
- 1. You need to take a trip by car to another town that you have never visited before. Therefore, you are studying a map to determine the shortest route to your destination. Depending on which route you choose, there are five other towns (call them A, B, C, D, E) that you might pass through on the way. The map shows the mileage along each road that directly connects two towns without any intervening towns. These numbers are summarized in the following table, where a dash indicates that there is no road directly connecting these two towns without going through any other towns. Miles between Adjacent Towns Town A B C D E Destination Origin 40 60 50 A 10 65 B 10 20 55 40 20 50 65 55 10 60 E 40 50 10 80 Formulate this problem as a shortest-route problem and find the shortest path.Python Programming: You are roaming in a random city and you have lost. You see a sign board and where that is return is that you can go to X and Y street if 1 <= Y - X <= K, where K is a value that is written on the board. You have to reach to your hotel in such a way that it is minimal. Input Output 31 10 251Problem-1: Check if an integer is Prime An integer greater than 1 is prime if its only positive divisor is 1 or itself. For example, 2, 3, 5, and 7 are prime numbers, but 4, 6, 8, and 9 are not. Key idea: To test whether a number is prime, check whether it is divisible by 2, 3, 4, and so on up to number/2. If a divisor is found, the number is not a prime. The algorithm can be described as follows: Use a boolean variable isPrime to denote whether the number is prime; Set isPrime to true initially; for (int divisor = 2; divisor <= number / 2; divisor++) { if (number % divisor == 0) { Set isPrime to false Exit the loop; } }