Questions tagged as 'int'

1
answer

sprintf does not give the expected result

I have variables of type Unsigned Long Int and would like to save its value in string , to perform checksum and send via serial communication.     void Payload (int long unsigned lastTime, float deltaOne, float deltaTwo, int factor...
asked by 16.02.2017 / 12:36
1
answer

How to convert a string to an integer in a socket program?

Here is a snippet of code: def CriarServer(self): Host = self.Txt1.get() Port = self.Txt2.get() sockobj = socket(AF_INET, SOCK_STREAM) #Erro sockobj.bind((Host, Port)) sockobj.listen(5) while True: da...
asked by 03.01.2017 / 20:13
2
answers

Somar int with date - PHP

I have the function below, which does the sum of date, with the value +2 days fixed: echo date('d/m/Y', strtotime("+2 days",strtotime($ultima_data))); It correctly sums up with the $ last_data value, but somehow needs to change the +2...
asked by 31.03.2016 / 16:38
2
answers

return CoreDat - Swift

I am not able to assign a textField with the result of a search when it is int, with String sure var results:NSArray = try context.executeFetchRequest(request) as! [NSManagedObject] if(results.count > 0){ var res = re...
asked by 23.10.2015 / 14:16
0
answers

"SIGSEGV ON THREAD", does anyone help me to solve, and also if possible, to complete the program?

It's the following, I do an info technician, and I'm learning C just two months, and I know little yet. Recently my teacher asked to make a program in which user entered with two number num, and that each position of two vectors n, were filled i...
asked by 19.06.2018 / 02:36
1
answer

Python transform a number into integer

import math x=9 raiz=math.sqrt(x) print raiz for i in range (raiz,9): #Problema aqui i=i**2 print i I need to create a for with the root of an operation (always integer 2, 3,4,5 ...) but when I try to use it the way I did the error. It says...
asked by 02.04.2018 / 04:14
0
answers

intval () changes values

Today I was doing a web application working with $ _REQUEST. But I noticed that when doing an UPDATE the value went out incorrectly, and when I looked at the functions in php, it was the most bizarre. Notice that intval () when it receiv...
asked by 04.04.2018 / 14:15
1
answer

How to convert a saved string to a .txt file, to an integer?

Example: test = open ('test.txt', 'w') test.write ('6000') test.close () How do I convert the contents of the .txt file to integer in order to be able to do operations with it? if you can not do this, how can I save data without losing it...
asked by 28.02.2018 / 18:02
1
answer

Desktop application position

Good evening guys I'm having a problem I'll try to explain: I created a desktop app and I need your position on the screen to take a photo ... 1st step get posY , and X with getX , GetY , already fis. I put these valu...
asked by 07.02.2018 / 20:49
0
answers

Change varchar data type to int

Is there any problem in changing the data type from varchar to int in mysql? I have a spreadsheet with some items that have been entered as varchar, all are numbers. The problem is that I need to do a bigger and smaller search, however, as it is...
asked by 03.01.2018 / 13:52