Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

1. Draw a flow chart to find the factorial of a number entered by the user. 2. Draw a flow chart that displays the squares

image text in transcribed
1. Draw a flow chart to find the factorial of a number entered by the user. 2. Draw a flow chart that displays the squares of all the positive integers up (and including) 100 (e.g. 1.4.9.16.25 ...). 3. Bank Muscat has launched a promotion for its Al Jawhar credit card customers. According to the promotion, the customers will receive a gift voucher worth OMR 50 with their monthly bill if they spend OMR 300 more than their last month spending and their last month bill is not less than OMR 800. Draw a flow chart showing the above process. 4. Follow is an algorithm to check whether a number entered by the user is prime or not. Draw the corresponding flow chart of this algorithm. Step 1: Start Step 2: Declare variables n, i, flag. Step 3: Initialize variables flag + 1 12 Step 4: Read n from the user. Step 5: Repeat the steps until 1-(n/2) 5.1 If remainder of nt equals 0 flag 40 Go to step 6 5.21 11 Step 6: If flag = 0 Display n is not prime else Display n is prime Step 7: Stop 5. Triangles can be classified according to their sides Equilateral triangle An equilateral triangle is a triangle in which all three sides are equal Isosceles triangle: An isosceles triangle is a triangle that has two sides of equal length Sculene triangle: A scalene triangle is a triangle that has three unequalsides, such as those illustrated above Design an algorithm and draw a flowchart to display the type of triangle (Equilateral Isosceles, Scalene) based on the length of the three sides of a Triangle provided by user as input

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Hands-On Database

Authors: Steve Conger

2nd Edition

0133024415, 978-0133024418

More Books

Students also viewed these Databases questions