Questions tagged as 'loop'

1
answer

Operation with lists of very large sizes

I have a code that calculates the area of the intersection between two polygons and for this I use lists to save the coordinates of the vertices of the polygons, however they are many polygons and it takes an average of 6h to run the whole code....
asked by 14.06.2016 / 05:54
1
answer

Creating an array with variables with different correlations in R?

I need to generate data series that have correlations defined using R. I used a method that I found here in the OS (#) and managed to create the variables with the desired correlation, however, when trying to automate this process for the creati...
asked by 31.03.2014 / 23:03
1
answer

Loop Error in R

I created this loop: library(forecast) a=1 b=60 while(b<=(NROW(tsarroz))){ janela=dput(tsarroz [a:b]) serie=ts(janela,freq=6) HW=HoltWinters(serie) prev=forecast(HW,6) result=data.frame(prev$mean) a=a+6 b=b+6 } It should cr...
asked by 10.10.2018 / 02:58
1
answer

Wait for thread to finish before closing program

I have a loop while that ends only when I press the q key, then the program quits. Within this loop , at a certain time or condition, I start a thread that takes a few 10 seconds to execute. My problem is, if I exit the loop...
asked by 26.03.2015 / 16:02
4
answers

Error Loop Java Class Scanner

When I use the nextLine () method in place of next () in the code below, code interactions are skipped and some fields are left blank. import java.util.Scanner; public class turma { public static void main (String args[]) { final...
asked by 28.10.2014 / 07:51
1
answer

Tie duplicating whole table

I can not make a loop in the table, it is looping every search in the database. $dbc = mysqli_connect('senha_adm'); $query = "select carro, barco, aviao, moto, triciclo, velotrou, dataCadastro from agencia"; $result = mysqli_query(...
asked by 01.09.2016 / 16:46
3
answers

Error in variable declaration in loop

I made the following command: for(int i = 1 ; i <= 3 ; i++) {etc } So I gave the following error when I compiled: game.c:11:2: error: "for" loop initial declarations are only allowed in C99 mode for(int i = 1 ; i <= 3 ; i++) { /\ //...
asked by 18.09.2015 / 01:14
3
answers

Why is an asterisk left?

I want the number of rows and columns in the output of my program equal to the given input . Why is the latter left over?? Code: #include<stdio.h> #include<math.h> int row = 0; char column = 0; int n; int main ( void ) {...
asked by 13.12.2016 / 03:06
2
answers

Delete files created more than 10 days ago, saving the most recent, if everyone on the list has more than 10 days of creation

I did this question where the question was how to delete files with more than 10 days of creation. I retrieve them from a directory and the code has already been implemented and is functional. However, I ended up with a problem that could c...
asked by 17.08.2016 / 20:31
1
answer

Why does Facebook's XHR requests have this code?

I was analyzing Facebook's XHR requests for study purposes and I came across a code that I found to be curious. Inthelinksimilartothis4-edge-chat.facebook.com/pull,ithasthefollowingcode:for(;;);{"t":"fullReload","seq":3} Well! As far as I...
asked by 14.01.2015 / 12:44