Answered step by step
Verified Expert Solution
Question
1 Approved Answer
above is the career salaries I will be needing to use for the program down below. where do I attach the comments of salaries and
above is the career salaries I will be needing to use for the program down below. where do I attach the comments of salaries and career titles?
import java.util.Scanner; public class Careers { public static void main(String[] args) { Scanner scanner = new Scanner(System.in); int count = 0; int minSal = 0, maxSal = 0; String minTitle = "", maxTitle = ""; String line; while (true) { System.out.print("Please enter(title $salary): "); line = scanner.nextLine(); if (line.length() == 0) break; String words[] = line.split("\\s+"); if (words.length ==1) { if (words[0].charAt(0) == '$') { System.out.println("Invalid input - no title: " + line); } else { System.out.println("Invalid input - no $: " + line); } continue; } if (words[words.length-1].charAt(0) != '$') { System.out.println("Invalid input - no $: " + line); continue; } int commas = 0; for (int i = 0; i sal) { minSal = sal; minTitle = line.substring(0,line.lastIndexOf(' ')); } else if (maxSal Database Architects $88,510 Network and Computer Systems Administrators $ 81,100 Computer Network Architects $104,650 Computer Network Support Specialists $62,340 Computer Programmers $82,240 Computer and Information Research Scientists $ 114,520 Software Quality Assurance Engineers and Testers $88,510 Computer Systems Engineers/Architects $88,510 Computer Systems Analysts $88,270 Web Administrators $ 88,510 Database Administrators $87,020 Information Security Analysts $ 95,510 Computer and Information Systems Managers $ 139,220 Software Developers, Systems Software $107,600 Software Developers, Applications $101,790 Web Developers $67,990
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started