Skip to content

Instantly share code, notes, and snippets.

@OlgaKulikova
Last active August 29, 2015 14:10
Show Gist options
  • Save OlgaKulikova/31bb7a5a505e513716df to your computer and use it in GitHub Desktop.
Save OlgaKulikova/31bb7a5a505e513716df to your computer and use it in GitHub Desktop.
module1.lesson4.task1
package module1.lesson4.task1;
/*
Написать функцию, которая принимает в качестве аргументов одну строку X, целое число Y и число с плавающей точкой Z
и возвращает как результат строку в виде
S = x + y + z.
*/
public class Main {
public static void main(String[] args) {
System.out.println(createText("String", 5, 2.9));
}
public static String createText(String someString, int i, double d) {
return "S = " + someString + " + " + i + " + " + d;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment