-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathcowsignal.java
More file actions
39 lines (28 loc) · 1.03 KB
/
cowsignal.java
File metadata and controls
39 lines (28 loc) · 1.03 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
import java.io.*;
import java.util.ArrayList;
import java.util.StringTokenizer;
public class cowsignal {
public static void main(String[] args) throws IOException {
// write your code here
BufferedReader f = new BufferedReader(new FileReader("cowsignal.in"));
// input file name goes above
PrintWriter out = new PrintWriter(new BufferedWriter(new FileWriter("cowsignal.out")));
StringTokenizer st = new StringTokenizer(f.readLine());
int x = Integer.parseInt(st.nextToken());
int y = Integer.parseInt(st.nextToken());
int k = Integer.parseInt(st.nextToken());
for(int i = 0; i<x;i++){
String m = f.readLine();
for(int l = 0; l<k;l++) {
for (int j = 0; j<m.length();j++) {
char lm = m.charAt(j);
for(int hehe = 0; hehe<k;hehe++){
out.print(lm);
}
}
out.println();
}
}
out.close();
}
}