package com.codegym.task.task02.task0205;
/*
Pay raise
*/
public class Solution {
public static void main(String[] args) {
salary(7000);
}
public static void salary(int a) {
//write your code here
//int pr = a + 1000;
//System.out.println("Your salary is: " + pr + " dollars per month.");
System.out.println("Your salary is: " + (a + 1000) + " dollars per month.");
}
}
Task already been solved. I'm just curious to which of my two answer is the better solution.
Under discussion
Comments (1)
- Popular
- New
- Old
You must be signed in to leave a comment
Ghanakiran
27 August 2018, 05:11
You go with already stored variable pr.
0