Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

Java Java Basics Getting Started with Java Introduction to Your Tools

About the learning way

O.K. So I am just a little confused so I will explain why, I am in uni and taking a Java class. Our instructor is horrible so I figured I would try teamtreehouse to help as I know you are all very good at what you do. How ever I am confused because your methods is absolutely completely different code wise. Like they make you use System.out.println and System.out.print and etc. but you use printf so Is this course reccomended to go along with a uni course? because . The last thing I want is to get even more confused then the Uni teacher has me but I really need to get good in regular java.

2 Answers

System.out.printf is a method used to print out formatted text.
I was not taught it in my course either, as my teacher wanted to take a more object oriented approach, using classes like DecimalFormat instead. System.out.print and System.out.println are also much simpler for people who are new to Java/programming, and don't yet need to worry about that kind of thing.
Once you get to the bigger concepts like Object Oriented Programming and Inheritance, these small differences wont be as relevant. Stick with it and it will all make sense soon!

So if I just do the teamtreehouse course it will make me efficient in java even if its different then the uni course? Treehouse here teaches a 100 times better then the uni as i said I was just worried I was not learning the right java lol

There may be a few small differences, such as the one you have encountered with print, println, and printf, but once you get deeper in to the content, you will be able to note these differences and find workarounds.
Use treehouse to supplement your knowledge, but in cases like these try to stick to how your professor shows you. Having the knowledge of how to do things both ways will make you a better programmer in the end!