This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.javarush.test.level13.lesson04.task04; | |
import java.awt.*; | |
/* Класс BigFox | |
1. Исправь класс BigFox так, чтобы программа компилировалась. | |
2. Метод main менять нельзя. | |
*/ | |
public class Solution |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.javarush.test.level13.lesson11.home04; | |
/* Запись в файл | |
1. Прочесть с консоли имя файла. | |
2. Считывать строки с консоли, пока пользователь не введет строку "exit". | |
3. Вывести все строки в файл, каждую строчку с новой стороки. | |
*/ | |
import java.io.*; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.javarush.test.level13.lesson11.home04; | |
/* Запись в файл | |
1. Прочесть с консоли имя файла. | |
2. Считывать строки с консоли, пока пользователь не введет строку "exit". | |
3. Вывести все строки в файл, каждую строчку с новой стороки. | |
*/ | |
import java.io.*; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.javarush.test.level13.lesson11.home04; | |
/* Запись в файл | |
1. Прочесть с консоли имя файла. | |
2. Считывать строки с консоли, пока пользователь не введет строку "exit". | |
3. Вывести все строки в файл, каждую строчку с новой стороки. | |
*/ | |
import java.io.*; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[15:04:25] Илья Симиошин: public static void main(String[] args) throws IOException | |
{ | |
BufferedReader rd1 = new BufferedReader(new InputStreamReader(System.in)); | |
String rd = rd1.readLine(); | |
OutputStream ot = new FileOutputStream(rd); | |
rd = rd1.readLine(); | |
while (!rd.equals("exit")){ | |
ot.write(rd.getBytes()); | |
rd = rd1.readLine(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.javarush.test.level13.lesson11.home04; | |
/* Запись в файл | |
1. Прочесть с консоли имя файла. | |
2. Считывать строки с консоли, пока пользователь не введет строку "exit". | |
3. Вывести все строки в файл, каждую строчку с новой стороки. | |
*/ | |
import java.io.*; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.javarush.test.level13.lesson11.bonus03; | |
/* Битва роботов | |
1 Разобраться в том, что тут написано. | |
2 http://info.javarush.ru/uploads/images/00/00/07/2014/08/12/50f3e37f94.png | |
3 Смириться со своей участью и продолжить разбираться в коде. | |
4 ... | |
5 Порадоваться, что мы все поняли. | |
6 Изменить код согласно новой архитектуре и добавить новую логику: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.javarush.test.level14.lesson02.task02; | |
/* Bingo-2 | |
Исправь строчку 'Cat o = new Cat();' так, чтобы программа вывела "Bingo!" | |
*/ | |
public class Solution | |
{ | |
public static void main(String[] args) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.javarush.test.level14.lesson08.home03; | |
public interface Person | |
{ | |
public static class User implements Person | |
{ | |
void live() | |
{ | |
System.out.println("Usually I just live"); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.javarush.test.level14.lesson08.home10; | |
import java.util.LinkedList; | |
import java.util.List; | |
/* Исправить 4 ошибки | |
Исправить 4 ошибки в конструкторе NotIncapsulatedClass и отрефактори код | |
1. В класе NotIncapsulatedClass создать private методы initList, printListValues, processCastedObjects. | |
2. Метод initList должен заполнять значениями входящий параметр list: | |
- найди нужный блок кода в конструкторе, в котором list заполняется значениями |