#include <stdio.h>
#include <string.h>
int main()
{
char str[] = "SUMIT";
int len = strlen(str);
int i,j;
for(i = 0; i < len; i++)
{
for(j = 0; j < len; j++)
{
printf("%c ", str[j]);
}
printf("\n");
}
return 0;
}
#include <iostream.h>
#include <string.h>
int main()
{
char str[] = "SUMIT";
int len = strlen(str);
for(int i = 0; i < len; i++)
{
for(int j = 0; j < len; j++)
{
cout<<str[j]<<" ";
}
cout<<endl;
}
return 0;
}
class PatternProg
{
public static void main(String args[])
{
String str = "SUMIT";
int len = str.length();
for (int i = 0; i < len; i++)
{
for (int j = 0; j < len; j++)
{
System.out.print(str.charAt(j)+" ");
}
System.out.println();
}
}
}
using System;
class PatternProg
{
public static void Main()
{
string str = "SUMIT";
int len = str.Length;
for (int i = 0; i < len; i++)
{
for (int j = 0; j < len; j++)
{
Console.Write(str[j] + " ");
}
Console.WriteLine();
}
Console.ReadKey(true);
}
}
string = "SUMIT"
length = len(string)
for x in range(0, length):
for y in range(0, length):
print(string[y]+" ",end="")
print()