fork download
  1. #include <stdio.h>
  2.  
  3. int main(void) {
  4. int n = 5;
  5. for(int i = 1; i<=n;i++){
  6. for(int j = 1 ; j<=n ; j++){
  7. if(i == j )
  8. printf("\\");
  9. else
  10. printf("*");
  11. }
  12. printf("\n");
  13.  
  14. }
  15. return 0 ;
  16. }
Success #stdin #stdout 0s 5320KB
stdin
Standard input is empty
stdout
\****
*\***
**\**
***\*
****\