Pages

Showing posts with label Java. Show all posts
Showing posts with label Java. Show all posts

Monday, 16 June 2014

Difference Between String and StringBuilder




String

String Builder 

1. String is Immutable type.

1. StringBuilder is mutable type.
2. Existing object cannot be modified rather creates new object in the String pool. 

2. Existing object can be modified and and doesn't create any new object in heap. 
3. String is Thread Safe.

3. StringBuilder is not Thread Safe.

4. Many Unused object left to be garbage collected if many String object are modified. 

4. Unused objects are not left to be garbage collected.

Saturday, 2 November 2013

Difference between java and php




JAVA 

PHP

1. Java is an object oriented language

1. PHP is a scripting language. 
2. It provides better security than PHP
2. PHP has weaker security as compared to Java.
3.Frameworks are available for its every web architectural layer. 
3. No such facility available in PHP
4. Maintenance is easier . 
4. Maintenance is little difficult.
5. Project developed in java are costlier.
5. Project developed in PHP is little cheaper then Java.