Question: How do I compile and run a program in Java on my mac? 

I'm new.

Also I downloaded a program that was suggested to me on here called text wrangler if that has any bearing on the situation.

Answer: 
I will give you steps to writing and compiling code.
Use this example:

```
 public class Paycheck {
    public static void main(String args[]) {
        double amountInAccount;
        amountInAccount = 128.57;
        System.out.print("You earned $");
        System.out.print(amountInAccount);
        System.out.println(" at work today.");
    }
}

```

1. Save the code as `Paycheck.java`
2. Go to terminal and type `cd Desktop`
3. Type `javac Paycheck.java`
4. Type `java Paycheck`
5. Enjoy your program!
Download and install Eclipse, and you're good to go.  

<http://www.eclipse.org/downloads/>

Apple provides its own version of Java, so make sure it's up-to-date.  

<http://developer.apple.com/java/download/>

---

Eclipse is an [integrated development environment](http://en.wikipedia.org/wiki/Integrated_development_environment). It has many features, but the ones that are relevant for you at this stage is: 

* The source code editor
	+ With syntax highlighting, colors and other visual cues
	+ Easy cross-referencing to the documentation to facilitate learning
* Compiler
	+ Run the code with one click
	+ Get notified of errors/mistakes as you go

As you gain more experience, you'll start to appreciate the rest of its rich set of features.