+ 9
why d'not work this code that was heart
include <iostream.h> int main() { int i,j; int n=5; for(i=n/2;i<=n;i+=2) { for(j=1;j<n-i;j+=2) { cout<<" "; } for(j=1;j<=i;j++) { cout<<"*"; } for(j=1;j<=n-i;j++) { cout<<" "; } for(j=1;j<=i;j++) { cout<<"*"; } cout<<endl; } /*lower part */ for(i=n;i>=1;i--) { for(j=i;j<n;j++) { cout<<" "; } for(i=1;j<=(i*2)-1;j++) { cout<<"*"; } cout<<endl; } }
9 Antworten
+ 6
Sorry for that 10Ks
+ 6
ya
+ 5
this was my code?
+ 5
Whar is the lower part
+ 5
Pls test it