Tagged Questions
0
votes
2answers
20 views
regular expression to find special character & between xml tags
A xml string generated from another model will pass to me, it may contains some special character such as & in the text of the xml tag.
e.g.
<entry>
<key>state</key>
<value ...
7
votes
3answers
89 views
Does a binary tree contain another tree?
Alright guys, I was asked this question in an interview today and it goes like this:
"Tell if one binary tree is contained inside another binary tree or not (contains implies both in structure and ...
0
votes
2answers
16 views
Using JSoup to parse text between two different tags
I have the following HTML...
<h3 class="number">
<span class="navigation">
6:55 <a href="/results/result.html" class="under"><b>»</b></a>
...
-6
votes
1answer
56 views
Java Regex does not match - groups [duplicate]
I know that this kind of questions are proposed very often, but
I can't figure out why this RegEx does not match.
I want to check if there is a "M" at the beginning of the line, or not.
Finally, i ...
1
vote
6answers
119 views
Java Regex does not match
I know that this kind of questions are proposed very often, but
I can't figure out why this RegEx does not match.
I want to check if there is a "M" at the beginning of the line, or not.
Finaly, i want ...
0
votes
3answers
61 views
Java/Regex - finding a characters anywhere in a String
I have a series of strings that I am searching for a particular combination of characters in. I am looking for a digit, following by the letter m or M, followed by a digit, then followed by the letter ...
-5
votes
0answers
72 views
solution needed for regular expression (\\d+).(\\d+)\\s\\w{3} [duplicate]
Need a java regular expression. Input contains number and then followed by 3 character currency symbol (with or without white space). The currency symbol needs to capitalized.
My input is
some text ...
-8
votes
0answers
84 views
Regular Expression - Help needed [on hold]
Need a java regular expression. Input starts with number and then followed by 3 character currency symbol (with or without white space). The currency symbol needs to capitalized.
My input is
500 UsD
...
3
votes
5answers
78 views
Java Regex Matcher works, but String.split() doesn't
I am looking to use a one line String.split() to pull out the 'name' in a query I am writting..
The Pattern + Matcher works like expected, but I am pulling my hair out trying to figure out why ...
0
votes
4answers
39 views
split the lines which have words separated by more than one white space
I am parsing some text files line by line, my need is to split the lines which have words separated by more than one white space. please suggest me how to do this
sample text
John is ...
-2
votes
2answers
61 views
Is it possible to use Regex in HTML?
Alright, I am really new into this and might be a stupid question but I have a word "kirtna" that appears in more than 1000 HTML files that are saved in my assets folder. It's in proper HTML file ...
0
votes
0answers
45 views
Whitespace Removal, From a java string, with a direct MySQL source
Well, I have a problem with eliminating whitespace from java string, well i have looked at solution provided here in stackoverflow, but they don't seem to work in my particular case:
How to remove ...
-1
votes
3answers
50 views
how to reduce multiple punctuation marks to just one from text file in java
I have some text files that contain multiple punctuation marks, so I need to reduce those to single punctuation marks.
Here is some sample text:
They are working in London..... he is a Java ...
2
votes
3answers
61 views
regex pattern to match specific number pattern , skip if there different pattern
Requirement:
If pattern 57XXXXXXX OR 57XXXXXXX-X found in a sentence , then copy this matched pattern (X- denotes 7 integer number and 57 are constant values must be there), else ignore complete ...
1
vote
1answer
51 views
Regex for finding Java's format strings in JavaScript
In Java/Android, you can use Format strings to specify how some outlook is expected to look like. These Format strings can be passed to String.format() or Formatter(), for example.
Simple examples ...