Created
October 18, 2011 00:58
-
-
Save dgw/1294363 to your computer and use it in GitHub Desktop.
Problem 3, Quiz 1, COSI 11A (Fall 2011), Brandeis University
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 Name: Q1P3 * | |
* Description: The code from Quiz * | |
* 1, Problem 3 in the Fall 2011 * | |
* COSI 11A course at Brandeis. * | |
* Purpose: Demonstrating how the * | |
* given expressions really eval. * | |
\* ******************************** */ | |
public class Q1P3 { | |
public static void main(String[] args) { | |
int a = 5; | |
int b = 10; | |
int c = b; | |
a = a++; | |
b = --b; | |
c += a - (c--); | |
// The moment of truth | |
System.out.printf("a = %d\nb = %d\nc = %d\n", a, b, c); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment