CSE1321L Programming and Problem Solving Assignment Problem

Assignment Help C/C++ Programming
Reference no: EM132381523

CSE 1321L: Programming and Problem Solving I Lab

Lab 7

Loop Structures

Exercise #1: Design and implement a program (name it Shape) that uses nested for loops to printout the shape shown below. Document your code.

*
***
*****
*******
*********
***********
*************
***************

Exercise #2: Design and implement a program (name it SumEven) that uses while loops to read an integer number between 20 and 60, then the program prints out the entered value followed by the sum of all even integer values between 2 and the entered number (including the entered value if even). Use a while loop to validate the user input before determining and printing the sum. Document your code and properly label the input prompt and the outputs as shown below.

Sample run 1:

Entered value: 20
Sum of even numbers between 2 and 20 is 110

Sample run 2:

Entered value: 25
Sum of even numbers between 2 and 25 is 156

Sample run 3:

Entered value: 60
Sum of even numbers between 2 and 60 is 930

Exercise #3: (Symbol) Write a nested loop that asks the user for symbol (store in a char) and a number. The loop should output a rectangle (or square) of the character that is of the height and width of the number. E.g., if I input 4 and *, I would get:

****
****
****
****

Instructions:

1. Programs must be working correctly.
2. Programs must be completed and checked before working the assignment.
3. Programs must be checked by the end of the designated lab session.

Reference no: EM132381523

Questions Cloud

Discuss commonly diagnosed childhood disorder : Childhood disorders often gain popularity during a specific time, such as Autism and ADHD. Select a commonly diagnosed childhood disorder and discuss.
What will the consequences be for ahmed : If the school finds out, what will the consequences be for Ahmed? Please explain fully.
Adaptive challenges come in many shapes and forms : Adaptive challenges come in many shapes and forms, List and discuss the four Adaptive Challenge Archetypes.
How change and stress can impact a person life : Normative and non-normative events help us understand how change and stress may impact our quality of life. Using the South University Library.
CSE1321L Programming and Problem Solving Assignment Problem : CSE 1321L Programming and Problem Solving I Lab Assignment help and solution, Assessment help - Write a nested loop that asks the user for symbol
Determine that the issue is pathological in nature : How can a therapist determine if a child's presenting issue can be accounted for based on typical development (e.g., Piaget's theory of cognitive development).
Make global code of ethics : If Kidder interviewed you, how would you answer the question "If you could help make global code of ethics, what would be in it?"
Inner-city children and teach them rock climbing : Cooper wants to start a sports club to benefit inner-city children and teach them rock climbing, mountaineering, and other outdoor sports.
PCN605 Psychopathology and Counseling Question : PCN605 Psychopathology and Counseling assignment help and solutions, Grand Canyon University, assessment help - What information do you gather from the data.

Reviews

Write a Review

C/C++ Programming Questions & Answers

  Differences between a while loop and a do-while loop

What are the differences between a while loop and a do-while loop?

  Section instance variables and encapsulation

What is the public interface of the counter class in section instance variables and encapsulation?

  Object-oriented systems is the concept of object

At the heart of all object-oriented systems is the concept of an object. Simply stated, an object is a set of related characteristics and their associated actions.

  Create the need matrix

Creating a system having five process from p0 to p4 and five resource types.

  Write a menu-driven c program

Write a menu-driven C program with appropriate functions that allows the user to fill an array of 50 integers with random numbers on the range 1...999, inclusive, sort it, and then find search it to determine if a given random number was generated..

  Write a function that takes two point arguments

Write a function that takes two POINT arguments and returns the midpoint between them and define a function distance() that takes two POINT arguments and returns the distance between them.

  Prepare a program that uses at least two functions that can

prepare a program that uses at least two functions that can be called from your main. this program is a number game

  Write a test program that creates an account object

Write a test program that creates an Account object with an ID of 1122, a balance of 20000USD, and an annual interest rate of 4.5% - Use the withdraw method to withdraw 2.500USD, use the deposit method to deposit 3000USD and print the balance, mont..

  Write a cpp program to find fibonacci numbers

Only one program, Write a C++ Program to Find Fibonacci Numbers using Dynamic Programming.

  Write c program that allows user to make ledger transactions

Write a C program that allows the user to make some ledger transactions. The program should first prompt the user to enter the current balance of his/her ledger account (must allow for dollars and cents, and not less than zero).

  Develop a program for students to practise arithmetic skills

ECSE1CES - C Programming for Engineers and Scientists - The principal from your primary school found out that you are doing your programming assignment

  Write program that has you enter years worth of monthly sale

You sell the book C++ for Fools. Write a program that has you enter a year's worth of monthly sales (in terms of number of books, not of money).

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd