Advertisement
TrashScrape

Headphones

Nov 25th, 2021
1,039
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.48 KB | None | 0 0
  1. public class Headphones {
  2.     String charge = "Micro usb"
  3.     String[] controls = {"power", "volume", "skip", "play/pause";
  4.     String color = "Red/black"
  5.    
  6.     static boolean power = false
  7.     static int volume = 0;
  8.    
  9.     public static void powerOn(){
  10.         power = true;
  11.     }
  12.     public static void powerOff(){
  13.         power = false;
  14.     }
  15.     public static void volumeUp(){
  16.         volume++;
  17.     }
  18.     public static void volumeDown(){
  19.         volume--;
  20.     }
  21.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement