C++ Programs & Projects
C++ Projects
C++ Programs
C++ Shapes Code
C++ Books Solutions
About US
Submit Post
Menu
Home
C++ Projects
C++ Programs
C++ Shapes Code
QT C++ Projects
QT C++ Programs
Learn C++ in URDU
Learn C++ in English
Learn Data Structures And Algorithms
C++ Books Solutions
Buy C++ Books
Disclaimer
Contact US
About US
Sitemap
Submit Post
Wednesday, 29 October 2014
Draw triangle shape in C++ code in which user enter its desire size of triangle. Using nested for loop and asterisk
Leave a Comment
Code :-
#include <iostream>
using namespace std;
int main()
{
int numb=0;
cout<<"Enter Value for size of triangle : = ";
cin>>numb;
for(int i=0;i<numb;i++)
{
for(int b=numb;b>i;b--)
{
cout<<"*";
}
cout<<endl;
}
return 0;
}
Output
If You Enjoyed This, Take 5 Seconds To Share It
Facebook
Twitter
Google+
StumbleUpon
Digg
Delicious
LinkedIn
Reddit
Technorati
0 Questions:
Post a Comment
Newer Post
Older Post
Home
Popular Posts
Write a C++ program that displays your name and address
Questions: Write a C++ program that displays your name and address (or if you value your privacy, a fictitious name and address) Explana...
Write a program to display the following output using a single cout statement. Subject Marks Mathematics 90 Computer 77 Chemistry 69
2 -) Write a program to display the following output using a single cout statement. Subject Marks Mathemat...
Labels
arrays
Basic Problems
c language projects
C Primer Plus
C Projects
C Structures
C Tutorials
C/C++ Shapes
C++ Basic Problems
C++ Books Solution
C++ Functions
C++ Language
C++ Loops and Decisions
C++ Program Examples
C++ Programs
c++ projects
C++ Puzzles
C++ Shapes Code
C++ Structures
C++ Tips and Tricks
C++ Tutorials
Control Structures
CPP Enum
CPP Pointers
CPP Vector
cppexamples
CppStruct
CS201 Assignment Solution
Ds malik
File Handling in C++
fstream
Identifiers
if statement
language c
Learn C++
Linked List
Loops
nested loop
OOP
QTProgramming
Recursion
Sorting
Strings
VU Assignment Solution
0 Questions:
Post a Comment