Hi everyone,

I found some really strange behaviour of the 'range' function

range(1,5)
> 1:5
everything is OK

range(2,5)
> 2:6
NOT OK!

range(10,20)
> 10:29
NOT OK!

However, if I define the range like so
10:20
> 10:20
OK and obviously works for all you guys as well.

Am I missing some syntax or is this a bug?



Also: is there a way to redefine the default behaviour of the range-syntax? 
It's really annoying having to 'Int' everything when I'm just specifying 
limits that get coerced to 'Float' because of division but are otherwise 
'X.0'
N=2^3 -1
> 7
imid = (N+1)/2
> 4.0
range(imid-2, imid+2)
> ERROR: MethodError: 'range' has no method matching range(::Float64, ::
Float64)

Thanks for helping,
Juergen

julia build:
Version 0.4.1 (2015-11-08 10:33 UTC)
both:

   - x86_64-w64-mingw32
   - x86_64-linux-gnu
   






Reply via email to