Questions tagged [infinite]

An infinite structure or process is one which does not terminate. Infinite loops or structures may be bugs in certain contexts, but also may be desired behavior, particularly in server-processes or lazy languages.

An infinite structure or process is one which does not terminate. Infinite loops or structures may be bugs in certain contexts, but also may be desired behavior, particularly in server-processes or lazy languages.

1090 questions
4
votes
2 answers

How can you stop a long (perhaps an infinite loop) internal emacs command?

Sometimes emacs enter in a loop, and I can't do anything but kill it. I don't really know the exact key combination that I use to put it in that state. Something with CTRL and %
4
votes
2 answers

Javascript for loop with date

I am trying to iterate over every day in a month, but my for loop gets stuck (into endless mode): var today = new Date(); var numberOfDaysInMonth = new Date( today.getFullYear(), lastMonth, 0 ).getDate(); ... for ( var date = new Date(…
4
votes
2 answers

htaccess infinite redirect on password-protected subdirectory

I have a website with two subdirectories, /1/ and /2/, appended to the end of the base url. Subsite /1/ already exists, and I'm trying to work on /2/ behind an htaccess password wall. Going to the /1/ site works fine (and the root redirects all work…
larsiusprime
  • 935
  • 6
  • 14
4
votes
2 answers

Writing an infinite sum (of a function that has an integral) in Python

I am required to show that: The annoying thing is that c_i is equal to the integral of the function G. Here is my attempt. import numpy as np from scipy.integrate import quad def G(x,n): P =…
turnip
  • 2,246
  • 5
  • 30
  • 58
4
votes
5 answers

java maximum value of int

From java documentation int has a minimum value of -2,147,483,648 and a maximum value of 2,147,483,647 (inclusive). I have a class Test.java. public class Test { public static void main(String[] args) { int i=2147483647; //max…
Bhushan
  • 6,151
  • 13
  • 58
  • 91
4
votes
1 answer

Using Tumblr Like Button with Infinite Scroll

I'm trying to use the new Tumblr like buttons within Infinite Scroll (allowing your theme a like button on individual Tumblr posts from the homepage) they work for the first 15 posts of the first 'page' but then as soon as it loads another page the…
andbamnan
  • 1,285
  • 2
  • 11
  • 8
4
votes
4 answers

haskell infinite list of incrementing pairs

Create an infinite list pairs :: [(Integer, Integer)] containing pairs of the form (m,n), where each of m and n is a member of [0 ..]. An additional requirement is that if (m,n) is a legit member of the list, then (elem (m,n) pairs) should…
john stamos
  • 1,054
  • 5
  • 17
  • 36
4
votes
2 answers

Infinite Scroll on Drupal pagination skipping second page

I have a Drupal site, the homepage is a view of all site content. It is paginated and I am using the Masonry and Infinite Scroll jQuery plugins. The first page loads fine, and when you scroll down it does seem to work as it should. However, it's…
Anthony Vz
  • 41
  • 2
4
votes
1 answer

Infinite scroll breaking with masonry on Tumblr

I'm working on a tumblr theme where I'm trying to combine masonry with infinite scroll. Although masonry works, as soon as I add in infinite scrolling things start to break. The second page content is appearing behind the first page content, and…
John
  • 295
  • 3
  • 11
3
votes
3 answers

Haskell infinite loop with simply re-let action

I have such code: Prelude> let n = [1,2,3,4] Prelude> n [1,2,3,4] Prelude> 0:n [0,1,2,3,4] Prelude> let n = 0:n And when I type in Haskell interpreter after upper: Prelude> n I'm getting the infinite result: [0,0,0,0,0,0,0,0,0 And where printing…
user1131997
3
votes
2 answers

Keycloak causes loops in react application after I have just login on keycloak auth pag. Infinite Loop when redirect after login

I am using @react-keycloak/web for React app securing using keycloak. I have recently started using KeyCloak with React. My KeyCloak Docker is running on Port 8080 and my React application is running on 3000. When I try to login, the address bar…
womendev
  • 31
  • 1
  • 2
3
votes
1 answer

CouchDB "_changes" listener updates the doc, which triggers another change

I want to write a background program that will monitor the _changes feed of a CouchDB, and possibly update the document. The problem is that the update causes another _change, and I get an endless loop! What's the best way to avoid this? For…
Nick Perkins
  • 8,034
  • 7
  • 40
  • 40
3
votes
3 answers

Python: Infinite loop and GUI

I'm trying to write a python program with wxPython GUI. Program must to collect some information in background (infinite loop), but GUI should be active at this time. Like, if I click on the some button, some variable or another information must…
Andrew
  • 31
  • 1
  • 2
3
votes
1 answer

How to wraparound in the 64KB code segment in a program that stitches itself to its own tail, ad infinitum?

If the sequential execution of instructions passes offset 65535, then the 8086 will fetch the next instruction byte from offset 0 in the same code segment. Next .COM program uses this fact and continually stitches its entire code (32 bytes in…
Sep Roland
  • 33,889
  • 7
  • 43
  • 76
3
votes
3 answers

How to represent Infinity in floating/double values in C++?

As cppreference says "In IEEE 754, the most common binary representation of floating-point numbers, the positive infinity is the value with all bits of the exponent set and all bits of the fraction cleared.". I tried this code snippet, but I don't…