Most voted "int" questions
A data type used to represent integers.
Learn more…114 questions
Sort by count of
-
-1
votes2
answers928
views -
-1
votes2
answers59
viewsInteger values on the terminal
I need to sum the odd numbers between two values. In online compilers the code works as predicted, adding any odd input values and giving the expected output, but in my terminal (4.15.0-34-Generic)…
-
-1
votes1
answer2531
viewsinvalid operands to Binary % (have ' float' and ' int')
When I compile the code I get the error in the question title for the line res100=notas%100; How to solve ? Code: float…
-
-1
votes1
answer72
viewsConvert millions of STRING to INT - Javascript
I have a string 123.456.789 and when using parseint is returning 123456, how to do to return 123456789 ?
-
-1
votes1
answer1327
viewsHow to convert String to Int in C++
I’m not able to convert this simple program. how do you convert? #include <string.h> #include <stdlib.h> using namespace std; int main () { int i; string a; i = atol (a); } . Error…
-
-1
votes1
answer39
viewsHow do I consider just what number a user enters in an input? (python)
rabanada = int(input("Quantos quilos você pesa? ")) if rabanada > 100000: print("Você é gordo") else: print("Você tá magro, rlx") If the user type: "100 kilos", as I do for the program consider…
-
-1
votes1
answer109
viewsVector of large size in C
I’m studying the data types of the C language. And today I decided to create a vector of very large size, in this case, 10 8. So, I made a small code in which I declare this large vector (being that…
-
-1
votes1
answer42
viewsHow to assign the result of a while/for to a list so it can operate with the values
n = int(input("what range?")) f1=0 f2=1 cont = 1 while cont <= n: f3 = f1 + f2 f1 = f2 f2 = f3 if f3 % 2 == 0: print(f3) # Como eu somo os valores de f3 ou transformo ele em uma lista? cont += 1…
-
-1
votes2
answers543
viewsHow to generate random numbers without rethinking in Java?
Something similar to the code below. Numbers in the Random range that do not repeat public void sorteiaCartelaB() { for (int i=0; i < b.length; i++) { b[i] = (int)(Math.random() * 60 + 1); for…
-
-1
votes1
answer41
viewsFailed to convert nvarchar'Array' value to int data type
Hello. I’m having some trouble inserting values into a table. Explaining better, I get the AID generated in Account and need to insert it in Login. I was successful in consulting the AID generated…
-
-1
votes1
answer53
viewsWhy when I inform "1.93" gives error when converting to integer?
print('Calculadora de IMC') peso = input('Insira o seu peso (em kg): ') altura = input('Insira sua altura (em metros): ') IMC = int(peso) / int(altura)**2 When I set the height value to "1.93" an…
-
-2
votes1
answer38
viewsHow can I remove 'R$ xa0' from a obtained result?
I am collecting data from a particular site, where when collecting some values I am facing some difficulties and would like to help to solve. I have the following code: valores =…
-
-3
votes1
answer47
viewsAm I validating twice?
Hello, I have a Select in a form with values only integers. When receiving this information in PHP, I make the following validations: Because I’m already wearing (int) on line 297 and line 302, my…
-
-4
votes1
answer339
viewsHow do I compare a character in the range of an alphabet?
The question is this:: 1)Help the university set up the divisions of the programming laboratory. For this, write an algorithm that reads the student’s name and tells which division he is respecting…