0% found this document useful (0 votes)
198 views7 pages

String Programs of Ramana Sir

Uploaded by

m.anand2301
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
198 views7 pages

String Programs of Ramana Sir

Uploaded by

m.anand2301
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 7

String Programs By Ramana sir

Q1: write a java program to reverse a string?


Q2: write a java program to arrange a character in a string?
Input:” ram#123” output:”123#ram”
Q3: write a java program to count words in a string?
Q4: write a java program to find given string is palindrome or
not?
Q5: write a java program to convert string to char array
without using in build function?
Q6: write a java program to print sum of number present in a
string?
Input:” ash123” output: 6
Q7: write a java program to find index value “ash123” where
key=’s’?
Q8: input: “AssmnAN” output: A=2, A=3, m=1, n=1, N=1?
Q9: input:” Ramana” output:” R@m@n@”?
Q10: write a java program to count vowel characters in a
string?
Q11: write a java program to print vowel character in a string?
Q12: write a java program to maximum occurrence character
and its count in a string?
Input: ramana output: a=3?
Q13: write a java program to minimum occurrence character
and its count in a string?
Input: ramana output: r=1?
Q14: input: helloworld output: he121w2r3d?
Q15: input: RaMana output: rAmANA?
Q16: write a java program for initcap of string input:
india that is bharat output: India That Is Bharat
Q17: input: “java is very easy” output: avaj si yrev ysay”
Q18: write a java program to print palindrome words in a
string?
Input: eye level car boy? output: eye, level
Q19: write a java program to change upper case to lower
case?
Q20: input: Ramana
Output: R
Ra
Ram
Rama
Raman
Ramana
Q21: input: “easy very is java” output: “java is very easy”
Q22: write a java program to print words in a given string,
input: “Java Is Very Easy”
Output: Java
Is
Very
Easy
Q23: input: “ccaabbd” output: “aabbccd” (sort given string)?
Q24: write a java program to print substring of a string
Input: ”Malayalam”

mal ala lay aya yal ala


mala alay laya ayal yala alam
Malay alaya layal ayala yalam
Malaya alayal layala ayalam
Malayal alayala lalayam
malayala alayalam
malayalam
Q25: input: “ramana” output: rmn?
Q26: write a java program to find missing alphabet in a string
?
Input: “abc” output:”d e f g h I j k l……….”
Q27: input:”3124” output:3124 without using parseInt?
Q28: String = I love python Input: - “java” REPLACE WITH
“python” Output: - I love java?
Q29: Write a java program to check two strings are Panagram
or not?
Q30: Write a java program to check two strings are Anagram
or not?
Q31: write a java program to print missing vowels in a string?
Q32: write a java program to find occurrence of a character in
a string using replace method?
Q33: write a java program to split given array and store he
result into string array without using split ()?
Q34: create one string array, size=5, add 5 elements and print
it in reverse order?
Q35: write all permutation of string “abc” output: “abc”,
“acb”, “bac”, “bca”, “cba”, “cab”?
Q36: write a java program to find palindrome substring in a
program?
Input: “Malayalam”
Output: ala, aya, layal, Malayalam
Q37: input: “happy happy birthday” output: “happy
birthday”?
Q38: write a java program smallest substring palindrome in a
given string?
Q39: write a java program to swap two string variables
without using third variable?
Q40: input: “acb243d10” output:213+10=253?
Q41: input: “abc” output:97+98+99=294?
Q42: Write a java program to remove space in given String
without using inbuilt function?
Q43: Write a java program to count number of characters
available in each word of a given String?
Input:- “java is easy” Output:- java=4 is=2 easy=4
Q44: Write a java program to find the occurrence of character
from given String with replace method?
Q45: Remove Extra space in given string
Input:__java__is___very__easy__?
Ouput: “java_is_very_easy”
Q46: Write a java program to check two strings are Anagram
or not without replace method?
Q47: input: “ramana” output:”ramn” with indexOf method?
Q48: write a java program to find missing alphabet in a string
by using indexOf method?
Q48: input: class key=$ output: cla$$?
Q49:write a java program to remove edge space using trim()?
Input:”__java _is _easy__? Output: “java is easy”?
Q50: write a java program , when count of vowels becomes
greater than 3 , then replace all vowels with space else keep it
as it was earlier?
Input:abeijho if count of vowels> 3 output: _b__jh_

You might also like