@c -*-texinfo-*-
@c This is part of the GNU Emacs Lisp Reference Manual.
@c Copyright (C) 1990, 1991, 1992, 1993, 1994, 1995, 1998, 1999
-@c Free Software Foundation, Inc.
+@c Free Software Foundation, Inc.
@c See the file elisp.texi for copying conditions.
@setfilename ../info/numbers
@node Numbers, Strings and Characters, Lisp Data Types, Top
@ifnottex
-2**27
@end ifnottex
-@tex
+@tex
@math{-2^{27}}
@end tex
-to
+to
@ifnottex
2**27 - 1),
@end ifnottex
-@tex
+@tex
@math{2^{27}-1}),
@end tex
but some machines may provide a wider range. Many examples in this
give these arguments the name @var{number-or-marker}. When the argument
value is a marker, its position value is used and its buffer is ignored.
+@defvar most-positive-fixnum
+The value of this variable is the largest integer that Emacs Lisp
+can handle.
+@end defvar
+
+@defvar most-negative-fixnum
+The value of this variable is the smallest integer that Emacs Lisp can
+handle. It is negative.
+@end defvar
+
@node Float Basics
@section Floating Point Basics
(lsh 3 2)
@result{} 12
;; @r{Decimal 3 becomes decimal 12.}
-00000011 @result{} 00001100
+00000011 @result{} 00001100
@end group
@end example
(lsh 6 -1)
@result{} 3
;; @r{Decimal 6 becomes decimal 3.}
-00000110 @result{} 00000011
+00000110 @result{} 00000011
@end group
@group
(lsh 5 -1)
@result{} 2
;; @r{Decimal 5 becomes decimal 2.}
-00000101 @result{} 00000010
+00000101 @result{} 00000010
@end group
@end example
@example
@group
;; @r{Decimal 134,217,727}
-0111 1111 1111 1111 1111 1111 1111
+0111 1111 1111 1111 1111 1111 1111
@end group
@end example
@example
@group
;; @r{Decimal @minus{}2}
-1111 1111 1111 1111 1111 1111 1110
+1111 1111 1111 1111 1111 1111 1110
@end group
@end example
@end defun
@example
@group
-(ash -6 -1) @result{} -3
+(ash -6 -1) @result{} -3
;; @r{Decimal @minus{}6 becomes decimal @minus{}3.}
1111 1111 1111 1111 1111 1111 1010
- @result{}
+ @result{}
1111 1111 1111 1111 1111 1111 1101
@end group
@end example
(lsh -6 -1) @result{} 134217725
;; @r{Decimal @minus{}6 becomes decimal 134,217,725.}
1111 1111 1111 1111 1111 1111 1010
- @result{}
+ @result{}
0111 1111 1111 1111 1111 1111 1101
@end group
@end example
@var{integer}, and vice-versa.
@example
-(lognot 5)
+(lognot 5)
@result{} -6
;; 5 = @r{0000 0000 0000 0000 0000 0000 0101}
;; @r{becomes}
of @code{random}. On other machines, the result can never be larger
than a certain maximum or less than a certain (negative) minimum.
@end defun
+
+@ignore
+ arch-tag: 574e8dd2-d513-4616-9844-c9a27869782e
+@end ignore