Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

diffrence b\w println() and printf()

Answer Posted / mohneesh

printf in Java works exactly as in C.

it automatically formats your string, which is not possible
in println directly.

System.out.printf("%s\n\t%s","Mohneesh","Wadhwani");

Output:
Mohneesh
Wadhwani

where as you can use String Formatter to format String then
pass it to println to print.

Is This Answer Correct ?    16 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Difference between final and effectively final ? Why is effectively final even required ?

993


Explain the difference between the public, private, final, protected, and default modifiers?

1044


How many ways can an argument be passed to a subroutine and explain them?

1030


What exactly is a .class file?

1047


Is java a digit method?

1000


How do I print a “?

997


How are observer and observable used in java programming?

1029


difference between byte stream class and character stream class?

4558


What is super constructor?

998


what is interface in java? Explain

969


Is 0 an irrational number?

1068


Which class should you use to obtain design information about an object in java programming?

1079


Why vector class is used?

993


What is the use of arrays tostring () in java?

1041


explain the difference between jdk and jvm?

999