Define Class Replace with the following details
Class Name    Replace
Data members 

String str, substr

Member Functions

Replace()  Constructor.
Replace(String s) - A constructor to assign s to str
void display() -   To print values of st, substr and frequency of substr in str
voidgetword(String ss) - to assign ss (it is a string no blank space) to substr
intfind_frequency() - to find frequency of substr in str and returns the frequency substr can occur in sub word also.
            
For Eg.
Str = "fox jumped on the ox
Substr ="ox"
    It should return = 2 
    Also write main().
            







     
                     

Contact Us

REACH US

SERVICES

  • CODING
  • ON-LINE PREPARATION
  • JAVA & PYTHON

ADDRESS

B-54, Krishna Bhawan, Parag Narain Road, Near Butler Palace Colony Lucknow
Contact:+ 919839520987
Email:info@alexsir.com