fork(1) download
  1. import java.util.*;
  2. import java.lang.*;
  3.  
  4. class Main
  5. {
  6. public static void main (String[] args) throws java.lang.Exception
  7. {
  8. String line = "af asf af dassfdfsdf a dfa sd<text:text which i need to store";
  9. int pos = line.indexOf("<text:");
  10. if (pos > 0) {
  11. line = line.substring(pos+6); // 6 is the length of your "<text:" marker
  12. }
  13. System.out.println(line);
  14. }
  15. }
Success #stdin #stdout 0.06s 380160KB
stdin
Standard input is empty
stdout
text which i need to store