Question
JAVA Application I am using VIsual Studio to run the code below, and i have the Java extension pack. I am recieving errors when running
JAVA Application
I am using VIsual Studio to run the code below, and i have the Java extension pack. I am recieving errors when running this can somebody help?
import java.util.Scanner;
public class AutoLinkedinJobs {
public static void main(String[] args) {
// Declare variables
String keywords;
String browser;
String command;
// Create a scanner to read in user input
Scanner input = new Scanner(System.in);
// Prompt user to enter in keywords
System.out.println("Enter in keywords related to the job you want to apply to: ");
keywords = input.nextLine();
// Prompt user to enter in their preferred browser
System.out.println("Enter in your preferred browser: ");
browser = input.nextLine();
// Open up LinkedIn on the user's preferred browser
openLinkedin(browser, keywords);
// Read in user command
System.out.println("Enter in 'stop' to end program or press enter to continue: ");
command = input.nextLine();
// While loop to continue evaluating jobs until user commands to stop
while (!command.equals("stop")) {
// Prompt user to enter in keywords
System.out.println("Enter in keywords related to the job you want to apply to: ");
keywords = input.nextLine();
// Open up LinkedIn on the user's preferred browser
openLinkedin(browser, keywords);
// Read in user command
System.out.println("Enter in 'stop' to end program or press enter to continue: ");
command = input.nextLine();
}
// Close the scanner
input.close();
}
// Method to open up LinkedIn on the user's preferred browser
public static void openLinkedin(String browser, String keywords) {
// Code to open up LinkedIn on the user's preferred browser here
System.out.println("Opening LinkedIn on " + browser + " with keywords: " + keywords);
}
}
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