Open In App

Scala Byte /(x: Byte): Int

Last Updated : 14 Jan, 2020
Improve
Improve
Like Article
Like
Save
Share
Report

In Scala, Byte is a 8-bit signed integer (equivalent to Java’s byte primitive type). The method /(x:Byte) method is utilized to return the quotient of this value and x.

Method Definition: Byte /(x: Byte): Int
Return Type: It returns the quotient of this value and x.

Example #1:




// Scala program of Byte /(x: Byte)
// method 
  
// Creating object 
object GfG 
  
    // Main method 
    def main(args:Array[String]) 
    
      
        // Applying Byte /(x: Byte) function 
        val result = (64.toByte)./(12:Byte) 
          
        // Displays output 
        println(result) 
      
    


Output:

5

Example #2:




// Scala program of Byte /(x: Byte)
// method 
  
// Creating object 
object GfG 
  
    // Main method 
    def main(args:Array[String]) 
    
      
        // Applying Byte /(x: Byte) function 
        val result = (125.toByte)./(11:Byte) 
          
        // Displays output 
        println(result) 
      
    


Output:

11


Similar Reads

Scala String regionMatches(int toffset, String other, int offset, int len) method with example
The regionMatches(int toffset, String other, int offset, int len) method is used to check if two string regions are equal or not. However, here ignoreCase is not included. Method Definition:Boolean regionMatches(int toffset, String other, int offset, int len) Return Type: It returns true if two string region matches else it returns false. Example #
1 min read
Scala Int to(end: int, step: int) method with example
The to(end: int, step: int) method is utilized to return a range from the stated integer to the 'end', which is given in the arguments list and some step is also specified in the arguments list. Method Definition: def to(end: Int, step: Int): Inclusive Return Type: It returns the range. Example #1: // Scala program of Int to() // method // Creating
1 min read
Scala Int until(end: Int, step: Int) method with example
The until(end: Int, step: Int) method is utilized to return a range from the start value to exact previous value of specified end integer value. Here the range's values are jumping by step value. Method Definition: defuntil(end: Int, step: Int): collection.immutable.Range Return Type: It returns the range. Example #1: // Scala program of Int until(
1 min read
Scala Byte %(x: Int): Int
In Scala, Byte is a 8-bit signed integer (equivalent to Java's byte primitive type). The method %(x:Int) method is utilized to return the remainder of the division of this value by x Method Definition: Byte %(x: Int): Int Return Type: It returns the remainder of the division of this value by x. Example #1: // Scala program of Byte %(x: Int) // meth
1 min read
Scala Byte -(x: Int): Int
In Scala, Byte is a 8-bit signed integer (equivalent to Java's byte primitive type). The method -(x:Int) method is utilized to return the difference of this value by x Method Definition: Byte -(x: Int): Int Return Type: It returns the difference of this value by x. Example #1: // Scala program of Byte -(x: Int) // method // Creating object object G
1 min read
Scala Byte &(x: Int): Int
In Scala, Byte is a 8-bit signed integer (equivalent to Java's byte primitive type). The method &(x:Int) method is utilized to return the bitwise AND of this value and x. Method Definition: Byte &(x: Int): Int Return Type: It returns the bitwise AND of this value and x. Example #1: // Scala program of Byte &(x: Int) // method // Creatin
1 min read
Scala Byte *(x: Int): Int
In Scala, Byte is a 8-bit signed integer (equivalent to Java's byte primitive type). The method *(x:Int) method is utilized to return the product of this value and x. Method Definition: Byte *(x: Int): Int Return Type: It returns the product of this value and x. Example #1: // Scala program of Byte *(x: Int) // method // Creating object object GfG
1 min read
Scala Byte ^(x: Int): Int
In Scala, Byte is a 8-bit signed integer (equivalent to Java's byte primitive type). The method ^(x:Int) method is utilized to return the bitwise XOR of this value and x. Method Definition: Byte ^(x: Int): Int Return Type: It returns return the bitwise XOR of this value and x. Example #1: // Scala program of Byte ^(x: Int) // method // Creating obj
1 min read
Scala Byte /(x: Int): Int
In Scala, Byte is a 8-bit signed integer (equivalent to Java's byte primitive type). The method /(x:Int) method is utilized to return the quotient of this value and x. Method Definition: Byte /(x: Int): Int Return Type: It returns the quotient of this value and x. Example #1: // Scala program of Byte /(x: Int) // method // Creating object object Gf
1 min read
Scala Byte +(x: Int): Int
In Scala, Byte is a 8-bit signed integer (equivalent to Java's byte primitive type). The method +(x:Int) method is utilized to return the sum of this value by x Method Definition: Byte +(x: Int): Int Return Type: It returns the sum of this value by x. Example #1: // Scala program of Byte +(x: Int) // method // Creating object object GfG { // Main m
1 min read
Article Tags :