Questions tagged as 'string'

1
answer

Doubt on how to use Shift in Java

Well, I have a question on how to use Shift Left in java. I have a String representing a value in hexadecimal. Except I need to pass this value to binary. For this I use an integer variable to turn this String into a decimal number: int primei...
asked by 27.03.2017 / 03:14
1
answer

How do I sort string in the Insertion sort method?

I'm using the following method, however in the WHILE line it's error. Netbeans says    "bad operand types for binary operator" & & ", first type: boolean, second type: int". public boolean insertionSort(String a []) { if (a...
asked by 05.03.2017 / 02:46
2
answers

How to compare part of strings in C?

I only know how to compare two strings in C, but can I compare only part of a string? I wanted to develop a program that reads snippets of a complaint and based on those snippets give a suggested answer. Is it possible to read only snippets in C...
asked by 17.05.2018 / 12:11
1
answer

How to display the String value retrieved from the JSF session?

I'm having a problem trying to display a String value retrieved from the session in xhtml. What I want is to show the value of a String attribute (name attribute) of an object of the class I created (User class), which is stored in the session....
asked by 21.12.2016 / 05:21
1
answer

How to make the compiler recognize the. as decimal separator?

I made a simple C # code that gets a real number but only recognizes the "," as the decimal separator. When I do receive numbers that use the "." as a separator it ignores the point. For example, if you send "2.0", it receives "20". Here is the...
asked by 12.12.2016 / 04:00
1
answer

Program does not wait to read content received

I am creating a program that reads the student's name, the number of absences, 3 grades and returns if the student has passed, failed for failure or failed by average, knowing that the limit of absences is 15, the minimum grade for approval is 7...
asked by 25.02.2017 / 16:10
1
answer

Show string string typed

How to display values read inside a loop in Java? Ex: for(int i = 1; i <= 2; i++){ System.out.print("Nome: "); String nome = tecla.nextLine(); } ?? < - Make read names appear here     
asked by 15.02.2017 / 20:16
1
answer

Solve mathematical expressions in java using string

I can not make this code resolve the expressions contained in the database. In the bank, the expressions are like this: All the expressions registered in the bank follow the pattern described below: $expressao = "$x$op1$y$op2$z$op3$w$op4$k"...
asked by 15.11.2016 / 15:15
1
answer

I can not get some Strings from strings.xml

I want to get a String that is in the strings.xml file, but always gives the following error: java.lang.RuntimeException: Unable to instantiate activity ComponentInfo{com.macave.rastreador/com.macave.rastreador.AjudaActivity}: java.lang.NullP...
asked by 31.12.2016 / 10:40
1
answer

Function that reads a double from a string and returns the remainder of the string in C

Is there any function of the type? Which reads and stores or returns a double of a string and returns or passes the rest of the string pointer or will I have to do my own function? If no one has ideas how to do this function optimally?     
asked by 03.10.2016 / 21:55