w10schools
Login Register
  • Home
  • Tutorials
    • HTML, CSS
      • HTML, HTML5
      • CSS, CSS3
    • XML
    • JavaScript, AJAX
    • PHP
    • Ruby on Rails
      • Ruby
      • Rails
    • ASP.NET
      • ASP
      • C# .NET
    • Java
      • JSP
    • Databases
      • MySQL
      • MSSQL Server
      • Oracle
    • Web Server
      • Windows
      • Linux
      • Apache
      • IIS
    • Design
      • Dreamweaver
      • Flash
      • Photoshop
      • Fireworks
      • CorelDRAW
      • Illustrator
  • References
    • HTML
      • Bootstrap
    • CSS
      • CSS Selectors
      • Sass
    • JavaScript
    • Mobile Apps
      • Cordova
    • Ruby on Rails
      • Ruby
      • Rails
    • PHP
      • Function
      • Language
      • CodeIgniter
      • Phalcon
      • PHPUnit
      • Symfony
      • Drupal
      • Yii
      • Laravel
    • Perl
      • Perl
    • Python
      • Python
      • Django
      • NumPy
      • Pandas
      • scikit-image
      • scikit-learn
      • Statsmodels
      • Matplotlib
    • Lua
      • Lua
    • C, C++
      • C
      • C++
    • Server
      • Docker
      • Apache HTTP Server
      • Nginx
    • Database
      • PostgreSQL
    • Big Data
      • TensorFlow
    • Game Development
      • Phaser
      • LÖVE
  • Articles
    • News
    • General
      • Website Promotion
      • Online Advertising
      • Make Money Online
    • Editorials
    • Interviews
    • Web Roundups
  • Resources
    • Design
      • Fonts
      • Graphics
      • Vectors
      • Templates
      • UI (User Interface)
      • Brushes
      • Patterns, Backgrounds
      • Textures
    • Web Development
      • HTML, CSS
      • XML
      • JavaScript, AJAX
      • Ruby on Rails
      • PHP
      • Java
      • .NET
      • Python
      • Perl
      • Flash
    • Mobile Application Development
      • Mobile Development Tools
      • Swift
    • Online Services
      • Online Storage
      • Web Hosting
  • Tools
    • Generators
gcdlcm

int.gcdlcm(int2) â array Instance Public methods Returns an array; [int.gcd(int2), int.lcm(int2)]. 2.gcdlcm(2) #=> [2, 2] 3.gcdlcm(-7) #=> [1, 21] ((1<<31)-1).gcdlcm((1<<61)-1) #=> [1, 4951760154835678088235319297]

integer?

int.integer? â true Instance Public methods Always returns true.

lcm

int.lcm(int2) â integer Instance Public methods Returns the least common multiple (always positive). 0.lcm(x) and x.lcm(0) return zero. 2.lcm(2) #=> 2 3.lcm(-7) #=> 21 ((1<<31)-1).lcm((1<<61)-1) #=> 4951760154835678088235319297

next

int.next â integer Instance Public methods Returns the Integer equal to int + 1. 1.next #=> 2 (-1).next #=> 0

numerator

int.numerator â self Instance Public methods Returns self.

odd?

int.odd? â true or false Instance Public methods Returns true if int is an odd number.

ord

int.ord â self Instance Public methods Returns the int itself. ?a.ord #=> 97 This method is intended for compatibility to character constant in Ruby 1.9. For example, ?a.ord returns 97 both in 1.8 and 1.9.

pred

int.pred â integer Instance Public methods Returns the Integer equal to int - 1. 1.pred #=> 0 (-1).pred #=> -2

prime?

prime?() Instance Public methods Returns true if self is a prime number, false for a composite.

prime_division

prime_division(generator = Prime::Generator23.new) Instance Public methods Returns the factorization of self. See Prime#prime_division for more details.

Popular Articles
keepalive_disable Syntax: keepalive_disable none | browser ...; Default: keepalive_disable msie6; Context: http, server, location Disables keep-alive conn
-X -X FILEHANDLE -X EXPR -X DIRHANDLE -X A file test, where X is one of the letters listed below. This unary operator takes one argument, either a filen
Swiper - Mobile touch slider with hardware accelerated transitions Swiper - is the free and ultra lightweight mobile touch slider with hardware accelerated transitions (where supported) and amazing native behavior. It
File::Path - Create or remove directory trees NAME VERSION SYNOPSIS DESCRIPTIONERROR HANDLING NOTES DIAGNOSTICS SEE ALSO BUGS ACKNOWLEDGEMENTS AUTHORS COPYRIGHT LICENSE NAME File::Path - Crea
Working with Text Data Series and Index are equipped with a set of string processing methods that make it easy to operate on each element of the array. Perhaps most import


Page 384 of 11844

|< < Prev 381 382 383 384 385 386 387 Next > >|
  • Facebook
  • Tweet
  • Digg it
  • Stumbleupon
  • Delicious
  • Plus Share

Designed by : w10schools

service@w10schools.com

Our Partners: aeeble – Providing content publishing and search solutions