Program to display asterisks in the shape of a plus sign, C/C++ Programming

Write a program called plus that will display asterisks in the shape of a plus sign which has the height and width specified by the user. You must only allow entry of an odd number for the height. (Reuse the Java code you created for task 1.) When an odd number (n) has been entered, display a plus sign that is n asterisks tall and n asterisks wide.

Hints:

1.    Use multiple loops to create the plus shape, including nested loops

2.    Reuse the odd/even code you created in task 1

Enter Size: 10

SIZE MUST BE ODD

Enter Size: 12

SIZE MUST BE ODD

Enter Size: 15

Posted Date: 3/19/2013 5:23:40 AM | Location : United States







Related Discussions:- Program to display asterisks in the shape of a plus sign, Assignment Help, Ask Question on Program to display asterisks in the shape of a plus sign, Get Answer, Expert's Help, Program to display asterisks in the shape of a plus sign Discussions

Write discussion on Program to display asterisks in the shape of a plus sign
Your posts are moderated
Related Questions
Here is a short program. It prints out the value of a variable "x". Ernie and Bert disagree about what will be printed: Ernie says, the value gets changed in "changeX" so it will p

solve mesh and nodal analysis through c/c++?

Explain a class to model a banking system. The function members should allow initializing the data members, a query to facilitate for account and a facility to deposit and with

Talking to IO boards inside a computer or microcontroller depends upon the principles used by the microprocessor to address physical devices. On Motorola systems all devices connec

Byteland county is very famous for luminous jewels. Luminous jewels are used in making beautiful necklaces. A necklace consists of various luminous jewels of particular colour. Nec

How must runtime errors be handled in C++ - Runtime errors in C++ can be handled using exceptions. - This exception handling mechanism in C++ is developed to handle errors i

Are comments included during compilation stage and placed in EXE file as well? - No, comments encountered by compiler are disregarded. - Their only purpose is ease and guida

Help me evaluate suitable OpenCV filters to get an inital working tracking algorithm. In this case it's objects moving on water (sea) and since I have very limited OpenCV knowledge

Private derivation If no specific derivation is listed, then a private derivation is supposed. If a new class is derived privately from its parent class, then: The priva

P o i n t e r d e c l a r a t i o n f o r C l a s s : M m; M * p m; / / C la ss M i s d e c l a r e d a s