Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

22 changes: 21 additions & 1 deletion src/GettingHotInHere.java
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,27 @@ public class GettingHotInHere {
public static void main(String[] args) {
// The instantiation code for a Scanner instance.
Scanner scanner = new Scanner(System.in);
System.out.print("What is the temperature in °F: ");
System.out.print("What is the temperature in °F: ");
int number = scanner.nextInt();
System.out.println(number + "°F" );

double celsius = (number - 32) * (5.0/9);
System.out.printf("%.3f°C\n", celsius );
int ci = (int) celsius;
System.out.println(ci + "°C");
double celsius2 = celsius + 2;
String A = "If it were 2°C warmer it would be";
System.out.printf("%s %.3f°C\n", A, celsius2);











}
}
6 changes: 5 additions & 1 deletion src/MrRoboto.java
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,13 @@ public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);

// Concatenate the user response to this String.
String domo = "Domo arigato ";
String domo = " Domo arigato ";

System.out.print("My name is Mr. Roboto, are you Kilroy? ");
// Write your program here
String line1 = scanner.nextLine();
System.out.println(domo+line1);


}
}