Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package samkough.main;
- public class TapeDeck
- {
- public static void main(String [] args)
- {
- TapeDeckTest ta = new TapeDeckTest();
- ta.canRecord = true;
- ta.playTape();
- if (ta.canRecord == true)
- {
- ta.recordTape();
- }
- }
- }
- ------------------------------------------------------------------------------------------------------------------
- package samkough.main;
- public class TapeDeckTest
- {
- boolean canRecord = false;
- public void playTape()
- {
- System.out.println("tape playing");
- }
- public void recordTape()
- {
- System.out.println("tape recording");
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment