This file contains hidden or 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
| import java.util.Scanner; | |
| public class LabGrade | |
| { | |
| public static void main (String[] args) | |
| { | |
| // Declare constants | |
| double inWeight = 0.6; // in-class weight is 60% | |
| double outWeight = 0.4; // out-of-class weight is 40% | |
This file contains hidden or 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
| import java.lang.*; | |
| import java.util.Scanner; | |
| public class Program | |
| { | |
| static Scanner sc = new Scanner(System.in); | |
| public static void main(String[] args) { | |
| // Declare variables |
This file contains hidden or 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
| import java.util.Scanner; | |
| public class Paint { | |
| static Scanner sc = new Scanner(System.in); | |
| public static void main(String[] args) { | |
| // Declare variables to be used | |
| final int ONE_GAL_PAINT = 350; | |
| double width = 0.0, length = 0.0, height = 0.0, total = 0.0; |
This file contains hidden or 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
| # Python 2 Shell Executor | |
| # September 18, 2013 | |
| # Ryan Cohen | |
| import socket, sys | |
| from subprocess import call | |
| def main(): | |
| print "\nPython 2 Shell Executor" | |
| ip = socket.gethostbyname(socket.gethostname()) |
This file contains hidden or 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
| for (var i = 0; i <= 100; i++) | |
| { | |
| if (i % 3 == 0 && i % 5 == 0) { | |
| console.log("FizzBuzz!"); | |
| } | |
| else if (i % 3 == 0) { | |
| console.log("Fizz!"); | |
| } | |
| else if (i % 5 == 0) { | |
| console.log("Buzz!"); |
NewerOlder