Questions tagged [string-parsing]

The action of retrieving data from a string

String parsing is the action of extracting or modifying data pieces from a string. For example, one might parse a string to remove all quotation marks or to find all items inside quotation marks.

970 questions
-1
votes
1 answer

Parsing a String With Multiple Lines (C#)

I new with C# and in and I have some questions. I'm writing some program that get the following output from remote machine (using SSH): wwn = 5001248018b6d7af node_wwn = 5001248018b6d7ae wwn = 5001248118b6d7af node_wwn = 5001248118b6d7ae wwn =…
almog50
  • 75
  • 1
  • 8
-1
votes
1 answer

While loops for parsing fasta files

I have been given an assignment for a project with no previous programming experience. It asks to create a motif finder using while loops, incrementals and boo's. I believe I am on the right track but very uncertain as I have no programming…
jad12
  • 1
  • 1
-1
votes
2 answers

How do I get the number at the end of a string in batch?

I'm writing a batch command file that uses the local machine's hostname, and I need to extract the number at the end of the string. How do I get the number at the end of a string in…
-1
votes
3 answers

Perl: print a string between quotes only on lines that match a certain regexp

EDIT: I'm not just trying to solicit people writing this code for me.....I have been trying at this for about a day, and despite having a perl textbook, I still can't figure it out. Like I said, I CAN do it using grep/awk/sed, and also by piping…
asmvolatile
  • 522
  • 5
  • 22
-1
votes
2 answers

Select contents of parenthesis in substring (VB.NET)

I have a substring of text like so: Serial Port Name (COM 1) How would I go about getting the contents of the above parenthesis? Thank you in advance.
Rachael
  • 1,965
  • 4
  • 29
  • 55
-1
votes
2 answers

Linux bash script removing part of string line by line

After greping output of command i have get below result: PAPU 0 1000 GPRS ATTACH SUCC GB 2400 2382 2333 (10) 1244 GPRS ATTACH FAIL GB 1216 1219 1252 (10) 16000 GPRS…
Javid
  • 47
  • 2
  • 8
-1
votes
3 answers

Deleting img tag from string

I've got a string, $content, that contains:

Some random text

Now I want to delete the image tag:
Chiel
  • 83
  • 10
-1
votes
1 answer

pass value from running thread

I'll start of with a brief description: I'm building a system to monitor the temperatures in a chemical reactor as a school project. We measure with an arduino that sends the data as a string to a pc. On the pc we have a Java code to read out that…
Wouter
  • 149
  • 1
  • 3
  • 12
-1
votes
2 answers

Parse C# HTML String WITHOUT html parsers like AgilityPack

I have an HTML Table as below:

Title2

Content2
firefalcon
  • 500
  • 2
  • 8
  • 21
-1
votes
3 answers

Cleanest data structure to use when interpreting data from neatly-structured user commands (in C++)

I would like to write a simple in-house program that parses user commands written in a language of our team's own invention (but based closely on another program we are already familiar with). The command parser that I am working on now will simply…
Vladimir
  • 225
  • 1
  • 11
-1
votes
3 answers

Convert strings representing unit of time or distance to numeric

I would like to search a data.frame column with string distances and convert them to numeric fields. I would do the same on twitter style dates such as '3 days ago' using the same function. If I was starting with: x <- c("5 days ago", "1 day ago",…
-1
votes
2 answers

Convert comma separated string into several lists and ignore first 5 characters of string's first element Java

I'm pretty new in Java and now i have following problem which I'm trying to solve. I have a string like this: item1item2,item3,item4item5,item6,item7 and what i need to get is this 2 lists: {item2,item3,item4} {item5,item6,item7} Please note that…
errordmas
  • 65
  • 1
  • 8
-1
votes
4 answers

c# how to get specific string

Hi I am facing problem to get specific string. The string as below: string myPurseBalance = "Purse Balance: +0000004000 556080"; I want to get 4000 out only.
user2156169
  • 41
  • 1
  • 5
-1
votes
2 answers

Extract double number value with exponent from text

How could I extract a number of type double which may have exponent from a string with more character? For example extract 56.8671311035e-06 from "this is a string with a number inside 56.8671311035e-06 and the string continues here" I guess it…
anderZubi
  • 6,414
  • 5
  • 37
  • 67
-1
votes
1 answer

Function to find a string inside another string and then find any numbers after that string in PHP

I'm hoping someone can help me. I would like a PHP function that takes a string (X), and searches it for another string (Y). After Y is found (left to right search), the function will return only numbers found after Y but will not return numbers (or…
jonathanbell
  • 2,507
  • 5
  • 23
  • 40