...* The design is not robust as there are no statements for error handling and handling exceptions. To make this code more robust I would add error handling statements like the user can only enter numbers that are between 0 and 100. Also the user cannot enter any strings like winding and other data types, for other numbers and data types the system will display "invalid input. Please enter a number between 0 and 100." Also notice that it doesn't handle the case of entering 49. You need <= 49, as it is now, when you enter 49 all it will say is "how did u do?" same thing with entering 100 and for anything over 100. * How many levels of nesting are there in this design? There is one level of nesting in the design. * Provide a set of values that will test...
Words: 468 - Pages: 2
...Write a pseudocode statement that declares the variable cost so it can hold real number. • Floating-point variable cost 6. Write a pseudocode statement that declares the variable total so it can hold integer. Initialize the variable with the value 0. • Declare Real price = 99.95 • Display “the original price.’ • Input item original price • Display “price” 7. Write a pseudocode statement that assigns the value 27 to the variable count. • Count:=27 8. Write a pseudocode statement that assigns the sum of 10 and 14 to the variable total. • Set total = 10+14 9. Write a psudocode statement that subtracts the variable downPayment from the variable total and assign the results for the variable due. • Set due = total – downPayment 10. Write a psuedocode statement that multiplies the variable subtotal by .15 and assign the result to the variable totalFee. • Declare Int subtotal • Declare Int totalFee • Declare Int taxTotal = .15 • Set totalFee = subtotal * taxTotal Programming Exercise //Declare variables • String itemName • Real subtotal • Real saleTax • Real countryTax • Real saleTax • Real countryTax • Real...
Words: 375 - Pages: 2
...* The design is not robust as there are no statements for error handling and handling exceptions. To make this code more robust I would add error handling statements like the user can only enter numbers that are between 0 and 100. Also the user cannot enter any strings like winding and other data types, for other numbers and data types the system will display "invalid input. Please enter a number between 0 and 100." Also notice that it doesn't handle the case of entering 49. You need <= 49, as it is now, when you enter 49 all it will say is "how did u do?" same thing with entering 100 and for anything over 100. * How many levels of nesting are there in this design? There is one level of nesting in the design. * Provide a set of values that will test...
Words: 468 - Pages: 2
...Name: Nilofer Neubert Student ID: E1271319 NRIC NO: S8790069Z Course Title: ELT373: Film and Gender Assignment Number: Tutor- Marked Assignment 01 The ten-minute film sequence that this essay will be focusing on is between 23:00 to 28:55 of Double Indemnity. The mise-en-scene of this film sequence communicates many key masculine desires of Neff such as having strong will to remain in strict of control of situations that lead him to achieve his desires for money as well as to get Phyllis Dietrichson. A close look at the mise-en-scene of his sequence also reveals his deep and intense feelings of love towards Phyllis Dietrichson. This intense love for her makes him want to control her. Therefore, this essay will be focusing on how the setting, the editing processes used in the post-production stage of the film sequence, the costumes, lighting, and staging of the selected sequence communicates the above mentioned masculine desires of Neff, the protagonist and anti-hero of Double Indemnity. When looking at the setting and the editing processes used in the post-production of this film sequence, it is important to take note of the location of this film sequence, the close up shots that take place in this film sequence and “the order in which scenes are arranged as a chain of events occurring within a given duration” (German SU1-3 & 4). “One of the interpretative strategies that we can employ when analysing Double Indemnity is identifying...
Words: 1300 - Pages: 6
...I would first gather all the salespeople in a meeting, and see what their opinions on the new bonus structure was, and if anyone had any ideas on improvement for it. After gathering all that information I would then request a meeting with Larry, and in the meeting I would discuss the new bonus structure and ask him how he came up with this so that I can see from his perspective. I would also ask him why he only centered it on Samuel and James. After hearing his point of view I would ask him if there was any way we could possibly change the bonus structure so that everyone has a chance at achieving it. I would explain to him that we could have different bonus structures depending on the amount of sales one did fall into three different brackets, for example if someone besides Samuel or James hits at the top bracket they too are able to get the same bonus. And if they hit the middle or lower bracket they are still able to get some kind of incentive. I would also suggest that we give away weekly incentives if one person hits a certain goal for the week, thus keeping them motivated to try and hit their sales. If Larry was to have a rebuttal against my idea I would explain to him that in order for us to not have such a high turnover and downturn in sales we need to be able to make the bonus achievable for everyone and not just for Samuel and James, and keep all the sales people motivated. As for keeping the significant turnover and downturn in the sales department, I would...
Words: 339 - Pages: 2
...algorithm that prompts the user to enter his or her favorite color and stores the users input in a variable named color. Display “enter favorite color” Input variable=color 3. Write an assignment statements that perform the following operations with the variables a, b, and c. a. ADDS 2 to a and stores the result in b a+2=b b. Multiplies b times 4 and stores the result in a b*4=a c. Divides a by 3.14 and stores the result in b a/3.14=b d. Subtracts 8 from b and stores the result in a 8-b=a 4. Assume the variables result w, x, y, and z are all integers, and that w=5, x=4, y=8, and z=2. What value will be stored in result in each of the following statements? a. Set result = x+y 12 b. Set result = z*2 4 c. Set result = y/x 4 d. Set result = y-2 6 5. Write a pseudocode statement that declares the variable COST so it can hold real numbers. Declare real variable cost 6. Write a pseudocode statement that declares the variable TOTAL so it can hold integers. Initialize the variable with the value 0. Declare Real Price=0 7. Write a pseudocode statement that assigns the value 27 to the variable content. Count=27 8. Write a pseudocode statement that assigns the sum of 10 and 14 to the variable COUNT. Count=10+14 9. Write a pseudocode statement that subtracts the variable downPayment from the variable TOTAL and assigns the result to the variable DUE. DUE = downPayment – TOTAL 10. Write...
Words: 729 - Pages: 3
...The very thing that is now called the Christian religion was already in existence in Ancient Egypt, long before the adoption of the New Testament. The British Egyptologist, Sir E. A. Wallis Budge, wrote in his book, The Gods of the Egyptians [1969], The new religion (Christianity) which was preached there by St. Mark and his immediate followers, in all essentials so closely resembled that which was the outcome of the worship of Osiris, Isis, and Horus. The similarities, noted by Budge and everyone who has compared the Egyptian Ausar/Auset/Heru (Osiris/Isis/Horus) allegory to the Gospel story, are striking. Both accounts are practically the same, e.g. the supernatural conception, the divine birth, the struggles against the enemy in the wilderness, and the resurrection from the dead to eternal life. The main difference between the “two versions”, is that the Gospel tale is considered historical and the Ausar/Auset/Heru (Osiris/Isis/Horus) cycle is an allegory. Allegories are intentionally chosen as a means for communicating knowledge. Allegories dramatize cosmic laws, principles, processes, relationships and functions, and express them in a way easy to understand. Once the inner meanings of the allegories have been revealed, they become marvels of simultaneous scientific and philosophical completeness and conciseness. The more they are studied, the richer they become. The ‘inner dimension’ of the teachings embedded into each story make them capable of revealing several layers...
Words: 649 - Pages: 3
... What will be printed if the input is 51? Your grade is 51, You did OK 4. What will be printed if the user enters “Wingding”? It would cause an error 5. Is this design robust? No If so, explain why. If not, explain what you can do to make it robust. You would need to add lines to deal with things such as if an invalid integer was input, then have the program display “error” “please enter a new score” 6. How many levels of nesting are there in this design? 4 7. Provide a set of values that will test the normal operation of this program segment. 1 and 99 Defend your choices. 1 is the test for the lowest function and 99 will test the highest function. These numbers will run throughout the program and will test all stages to verify the program is running properly 8. Provide a set of test values that will cause each of the branches to be executed. 10 will test stage 1, 60 will test stage 2, 75 will test stage 3, and 90 will test stage 4 9. Provide a set of test values that test the abnormal operation of this program segment. J, #, -2, and 1000...
Words: 253 - Pages: 2
... ! ! ! ! ! ! ! ! Presented to Ms. Loschiavo! ! ! ! ! ! ! ! ! By! Khalid Sidki! 10 Red! Year Goals ! ! ! ! ! ! ! ! ! ! Victoria! October 3, 2014! ! ! ! ! ! ! ! ! ! ! ! ! ! ! Throughout my life I have learned to set high goals, reach for them, and achieve them. Attaining a goal is often a difficult process, but it wouldn't be a goal if it were easy. It is very important to me to be successful and to never settle for less than my full potential. I don't want to be average in anything that I do, but I wish to stand out as a person who works hard and doesn't give up.! ! ! ! My first goal is to attend class everyday. The first thing I will do is go to bed every night at a decent time. That way, I can be up in the morning on time and be prepared for class. I will also make sure I get to the bus stop in a timely matter each day, that way I will always get to my class on time. By succeeding in this objective, I won’t miss any valuable information and I will not arrive very tired or half asleep. ! ! ! ! Once I succeed, I must also hand in and complete my daily assignments. The first thing I will do each day is write assigned homework in my daily planner. That way I will remember what my assignments are at home. I will also set a designated time each night to do my homework. That way I will never forget to get it done. As a reward, I’ll become more organized and I won't lose any points for late assignments.! ! ! ! Finally, my personal goal is to study...
Words: 499 - Pages: 2
...the last value is the width of each ring. b. In the constructor, specify the appropriate window title using your lastName and assign the above instance variables with the values 150, 150, 100, and 12, respectively. Note that the ring width is different in this homework. c. In the paint method, a. Declare a variable named currentRadius and assign the outermostRadius to it. b. Declare an integer counter variable and initialize it with the value 0. c. Using a while construct, repeat the following steps as long as the currentRadius variable has a positive value. • If the counter is even valued, set the current color to blue. Otherwise, set the current color to pink. • Fill a circle using the specified center coordinates and the current radius value. • Decrement the current radius by the ring width. • Increment the counter. In the main method, create the application object, set its size to 300 by 300 and its visibility to true to test the above graphics HELPIDO.COM FOLLOW THIS LINK TO GET THE TUTORIAL ---------------------------------------------------- http://helpido.com/category/cs-520/...
Words: 251 - Pages: 2
...categorization process continues until each line segment that spans across a window boundary (hence encompasses an intersection point) reaches a threshold for line size and all other segements are either in category 1 (visible) or in category 2 (invisible). The midpoint coordinates (xm , ym) of a line joining (x1 , y1) and (x2, y2) are given by xm=x1+x22 ym=y1+y22 The Liang-Barsky algorithm for finding the visible portion of the line, if any, can be stated as a four-step process: 1. If pk = 0 and qk < 0 for any k, eliminate the line and stop. Otherwise proceed to the next step. 2. For all k such that pk < 0, calculate rk = qk /pk. Let u1 be the maximum of the set containing 0 and the calculated r values. 3. For all k such that pk > 0, calculate rk = qk/pk. Let u2 be the minimum of the set containing 1 and the calculated r...
Words: 367 - Pages: 2
...conspirators quickly picked up the cover, placed it upon the box, and nailed it down imprisoning the unsuspecting king. To make certain that Osiris would suffocate, they poured melted led over the box.Nut gave birth to 5 children.In time, Isis gave birth to Osiris’s son whom she named Horus.I shall teach you the words of power that will protect Horus from death on earth, in the world above, and in the other worldThe infant had been restored to lifeOnce Osiris was properly buried, Horus prepared to do his part to return his father to life. He led Isis and Nephthys to the world of the dead where they found Osiris.. gradually the dead god came to life.Horus then rore after Isis … when he caught her, he fought as fiercely as he had fought with set. Finally, Horus cut off her head.Thoth immediately used his magical words of power to change his daughters head into the head of a cow, and he quickly attached it to her body.Horus was chosen to be the intermediary between the living and the dead. Men and women would pray to him while they were still alive, asking him to notice their good lives and plead with Osiris for their resurrection after death. | This myth played a very big role in Egyptian...
Words: 450 - Pages: 2
...success Taking ownership of each class Putting in effort in the class to succeed Showing up for class Having proper class materials (books, pencils, paper etc) 3. Preliminary plan to practice personal responsibility in my education Setting goals On time assignments Studying Reading Knowing when to ask for help 4. Personal responsibility is directly tied to personal and professional success, whether at work, home, or school. Practicing and applying personal responsibility will help me in achieving the goals I have set to accomplish my goals in these areas Personal Responsibility Personal responsibility is being a person who is being a professional in the work place, and who takes responsibility of their own actions, to include showing up on time, being courteous to others, and the being a model employee. Part of personal responsibility in my profession is staying in compliance with all standards and regulation set forth to me. Personal responsibility extends beyond the work place. As a parent, being a positive role model for my kids instilling rules of the house. Personal responsibility goes into so many things aspect of our lives that isn’t feasible to include all the areas of personal responsibility. In my opinion personal responsibility is doing what I think is best for my family, work, and college success. Personal responsibility is something I plan on applying to ensure success in my education is by developing a plan, setting goals, and...
Words: 853 - Pages: 4
...Isis was the Egyptian goddess of rebirth and protection. She was the first daughter of Geb, god of the earth, and Nut, the goddess of the sky. She was very unlike the other Egyptian goddesses and became the most powerful goddess in the ancient world. She was also commonly referred to as Mother of Life and Crone of Death. Isis had married her brother Osiris, and he became the first king of the earth. Their brother Set, became immensely jealous of their powers and sought out to kill Osiris. Set did this by tricking him into stepping into a beautiful box built to only fit Osiris. He then sealed the box and threw it in the Nile and as time passes branches grew over the box, encapsulating the god into a wooden coffin. Isis, mad with grief, tore...
Words: 349 - Pages: 2
...number of requested data items (k), the query condition, and a list of the node identifiers of nodes on the path along which the query message is to be transmitted (Query path). The, query issuing node Mp transmits a query message whose Query path includes its identifier, Mp, to its neighbor nodes. A node, Mq, which receives the query, transmits a query according to the following steps: 1. If Mq receives the query for the first time then 2. . Store Query path and hop count as its Parent Query path 3. Store the nodeID at the end of Query path as its parent 4. Set RD for replying data items 5. Add Mq’s nodeID to the end of Query path and send the query to neighbor nodes 6. Else 7. Store Query path and hop counts as its Neighbor Query path 8. Store the nodeID at the end of Query path as its neighbor 9. end if Here, hop count denotes the number of hops to the query-issuing node. Then, Mq sets a waiting time for reply (RD). As hop count increases, RD decreases. When Mq receives the query later again, it stores the ID of the query sender node as its neighbor node, as well as, the Query path and the number of hops. When its RD has passed, each node sends back a reply message, which includes its own node identifier (Sender nodeID), the identifier of the next node along the reply route (Dest nodeID), an encrypted id (Enc ID), a list of the data items (including their scores) and the node identifiers of the nodes possessing them (Data list), and a list summarizing...
Words: 1999 - Pages: 8