Scala Int >=(x: Int) method with example

The >=(x: Int) method is utilized to return true if the specified int value is greater than or equal to the int value, otherwise false.

Method Definition: (Int_Value).>=(Int_Value)
Return Type: It returns true if the specified int value is greater than or equal to the int value, otherwise false.

Example #1:

filter_none

edit
close

play_arrow

link
brightness_4
code

// Scala program of Int >=(x: Int)
// method
  
// Creating object
object GfG
  
    // Main method
    def main(args:Array[String])
    {
      
        // Applying Int >=(x: Int) function
        val result = (66).>=(55)
          
        // Displays output
        println(result)
      
    }

chevron_right


Output:

true

Example #2:

filter_none

edit
close

play_arrow

link
brightness_4
code

// Scala program of Int >=(x: Int)
// method
  
// Creating object
object GfG
  
    // Main method
    def main(args:Array[String])
    {
      
        // Applying Int >=(x: Int) function
        val result = (50).>=(60)
          
        // Displays output
        println(result)
      
    }

chevron_right


Output:

false



My Personal Notes arrow_drop_up

Recommended Posts:

    Article Tags :

    Be the First to upvote.


    Please write to us at contribute@geeksforgeeks.org to report any issue with the above content.