Write a java Program to Perform String Operation

import java.util.*;
class StringOperation
  public static void main(String args[])
  String first=" ",second=" ";
  Scanner sc=new Scanner(System.in);
  System.out.print("Enter the first string1");
  System.out.print("Enter the second string2");
  System.out.println("The string are:"+first+","+second);
  System.out.println("The length of string is:"+first.length());
  System.out.println("The length of string is:"+second.length());
  System.out.println("The lowercase of"+first+"is:"+first.toLowerCase());
  System.out.println("The concatenation first and second string:"+first.concat(""+second));
  System.out.println("The first character of"+first+"is:"+first.charAt(0));
  System.out.println("The uppercase of"+first+"is:"+first.toUpperCase());
   System.out.println("The lowercase of"+first+"is:"+first.toLowerCase());
  System.out.println("The occurance of a character in "+first+":");
 String str = sc.next();
 char c = str.charAt(0);
 System.out.println("The "+c+" occurs at position" +first.indexOf(c)+ "in" +first);
 System.out.println("The substring of "+first+" starting from index1 and ending at 4 is:" +first.substring(1,4));
System.out.println("Replacing 'a' with 'o' in" +first+" is:"+first.replace('a','o'));
boolean check=first.equals(second);
System.out.println(first+"and"+second+" are not same");

System.out.println(first+"and"+second+" are same");


For more details about How to Earn Money Online please visit


College Projects with source code (PHP, .NET, JAVA, Visual Basic)

Pharmacy Management System in PHP and MySQL with Source Code

2018 Top WordPress Plugins for Business Websites

Top 10 Best Photo Editing Apps For Android

Best 2018 Android Hacking Apps

30 Best Free WordPress Blog Themes for 2017

Online Loan Management System

Car Rental System Using PHP

Online Jewellery Shopping System Php Project with source code

Online time table generation system in PHP

Online Examination System In PHP

PHP Website with DataBase As MySql

18 Ways to Earn Money Online from Home Without Investment

Online Survey Jobs: Earn from 20 Best Paid Survey Sites

Get Paid to Take Online Surveys for Money with 21 Best Sites

Top 10 Captcha Entry Job Sites

Best Get Paid to Offer & GPT Sites

Get Paid to Read & Click Ads from Best PTC Sites

How To Restore Your WordPress Website Backup On Local Server Using WAMP

Online Shopping System Using PHP and MySQL

Email server using PHP and MySQL

Hotel Reservation System In PHP

social media platforms Project In PHP

Crime Reporting System Project In PHP

Gmail Outlook Settings In Outlook 2016

Airlines Reservation System Java Project

Mail Server in PHP And MySQL

Online Examination System in PHP and MySQL

Student Information System using Vb and SQL

Payroll Management System In VB and SQL

Exam Seating Management System

Automation Inventory System in VB and SQL Server

School Management System


  1. Netflix mobile apps are available for Android, iOS, Windows platforms. You just have a premium membership of Netflix that’s all; you can enjoy your favorite TV shows or movies anywhere, anytime
    windows activators

    1. Check out this website for free projects www.coderush.cf

  2. Hi, Great.. Tutorial is just awesome..It is really helpful for a newbie like me.. I am a regular follower of your blog. Really very informative post you shared here. Kindly keep blogging. If anyone wants to become a Java developer learn from Java Training in Chennai. or learn thru Java Online Training in India . Nowadays Java has tons of job opportunities on various vertical industry.


Powered by Blogger.