# ITC558 | Programming Principles Assessment Item 1 | Information Technology

Home Assignment Answers ITC558 | Programming Principles Assessment Item 1 | Information Technology

• In this Assignment we have to write a program of ‘Shape Area Calculation System’ (SACS).
• First of all the program prints the welcome message i.e ‘Welcome to Shape Area Calculation’.
1. Triangle
2. Rectangle
3. Trapezoid
4. Circle
5. Ellipse
6. Parallelogram
• Prompt the user ‘Please select the shape you would like to calculate the area  for(1-6)’
• Get the input from user using method ‘raw_input()’ and store into a variable ‘user_input’
• Prints ‘Thank You!’.
• If user_input==1(Triangle)
• Prints ‘The shape you selected is:Triangle’.
• Prompts the user to enter the base(in centimeters ) and store value into a variable ‘base’.
• Prompts the user to enter the height (in centimeters) and store value into a variable ‘height’.
• Calculate the area using the formula ((base*height)/2) and display the result.
• If user_input==2(Rectangle)
• Prints ‘The shape you selected is: Rectangle’.
• Prompts the user to enter the length(in centimeters) and store value into a variable ‘length’.
• Prompts the user to enter the breadth (in centimeters) and store value into a variable ‘breadth’.
• Calculate the area using the formula (length *breadth) and display the result.
• If user_input==3(Trapezoid)
• Prints ‘The shape you selected is: Trapezoid’.
• Prompts the user to enter the base1 (in centimeters) and store value into a variable ‘base1’.
• Prompts the user to enter the base2 (in centimeters) and store value into a variable ‘base2’.
• Prompts the user to enter the height (in centimeters) and store value into a variable ‘height’.
• Calculate the area using the formula ((1/2(base1+base2))*height) and display the result.
• If user_input==4(Circle)
• Prints ‘The shape you selected is: Circle.
• Prompts the user to enter the radius (in centimeters) and store value into a variable ‘radius’.
• If user_input==5(Ellipse)
• Prints ‘The shape you selected is: Ellipse.
• Prompts the user to enter the length of Semi-Major Axis (in centimeters) and store value into a variable ‘semi_major_axis’.
• Prompts the user to enter the length of Semi-Minor Axis  (in centimeters) and store value into a variable ‘semi_minor_axis’.
• Calculate the area using the formula (3.14* semi_major_axis* semi_minor_axis)and display the result.
• If user_input==6(Parallelogram)
• Prints ‘The shape you selected is: Parallelogram’.
• Prompts the user to enter the base(in centimeters) and store value into a variable ‘base’.
• Prompts the user to enter the height(in centimeters) and store value into a variable ‘height.
• Calculate the area using the formula (base*height) and display the result.
• After the completion of the calculation print ‘ Thanks for using Shape Area Calculation System’
• Then Prints ‘Goodbye’ and exit.

#### Latest Reviews

• ##### Kannon
13 Jul, 2019

I asked for essay help from Assignment Help 4 Me and I am happy that the essay writers completed my task on time. The prices they asked for are worth in comparison to the services rendered.

• ##### Liam
13 Jul, 2019

Assignment Help 4 Me is the best help provider. I took assistance to get my essay completed and I am glad that the writers delivered the quality content as they promised within the time committed.

• ##### Silas
12 Jul, 2019

Accounting is a very interesting subject but when it comes to assignment writing, I feel hard to get through the same. But, since the assignments have to be completed somehow, I preferred to avail online help from Assignment Help 4 Me. All thanks to them that they helped me complete my work on time at reasonable prices.