We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 6617bbd commit 129b872Copy full SHA for 129b872
src/main/java/com/eprogrammerz/examples/general/regexexample/HtmlTagRegexExample.java
@@ -0,0 +1,15 @@
1
+package com.eprogrammerz.examples.general.regexexample;
2
+
3
+/**
4
+ * Created by 542596 on 3/9/2017.
5
+ */
6
+public class HtmlTagRegexExample {
7
+ public static void main(String[] args) {
8
+ String htmlString = "<prs>contents</pr>";
9
+ String tagRemovedString = htmlString.replaceAll("<[A-Za-z]+>|</[A-Za-z]+>","");
10
+ System.out.println(tagRemovedString);
11
12
+ //you can not compare with null in either parameter
13
+ System.out.println("yogen".compareToIgnoreCase(null));
14
+ }
15
+}
0 commit comments