1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
LenKa [72]
3 years ago
12

An application used by the Human Resources (HR) department needs to be improved. You need to use various string manipulation pro

perties and methods to ensure all data entered by a user is accurate and stored correctly. The users of the HR application have entered some employee Social Security numbers (SSNs) with dashes (such as 222-33-4444) and some without dashes (such as 222334444). You need to remove all dashes from any SSN that contains dashes. You will use the __ method to edit the code so that only numeric characters are stored.
a. Remove
b. Substring
c. Replace
d. Trim
Computers and Technology
1 answer:
Verizon [17]3 years ago
4 0

Answer:

a.Remove

Explanation:

Since there are extra characters in the string for example:-222-33-4444 we need 222334444 so there are two extra characters in the string and they are "-".So we need to remove extra characters from the string to get the final string.We cannot replace - since it has to be replaced by another character which will give the wrong string.Trim is used to remove leading and trailing spaces from the string. Substring provide another smaller string created from the original string.

You might be interested in
Which website navigation method consists of a single web page containing a list of hyperlinks representing all the pages in the
SpyIntel [72]

Answer:

i think it's main menu!

Explanation:

when your on the main menu , you find everything your looking for or what it is you need to go too because ur on the home page! let me know if this helped!

7 0
3 years ago
Read 2 more answers
, , ,g d,t ,dt m,dt ymtd
maks197457 [2]

Answer:ummm me confused

Explanation:

4 0
4 years ago
Write a client program ClientSorting2 and in the main() method: 1. Write a modified version of the selection sort algorithm (Sel
TEA [102]

Answer:

The program in Java is as follows:

import java.util.*;

public class Main{

 public static void SelectionSorter(String[] my_array){

     System.out.print("\nAfter sort: ");

     for (int ind=0; ind < 22; ind++ ){

         int min = ind;

         for (int k=ind+1; k < 23; k++ )

         if (my_array[k].compareTo(my_array[min] ) < 0 ){ min = k;  }

         String temp = my_array[ind];

         my_array[ind] = my_array[min];

         my_array[min] = temp;    }

   for (int j=0; j < 23; j++){   System.out.print(my_array[j]+" ");}

    }

public static void main(String[] args) {

 Scanner input = new Scanner(System.in);

 String [] myarray = new String [23];

 for(int i= 0;i<23;i++){ myarray[i] = input.nextLine();  }

 System.out.print("Before sort: ");

 for ( int j=0; j < 23; j++ ){        System.out.print(myarray[j]+" ");    }

 SelectionSorter(myarray);

}

}

Explanation:

This defines the function

 public static void SelectionSorter(String[] my_array){

This prints the header for After sort

     System.out.print("\nAfter sort: ");

This iterates through the array

     for (int ind=0; ind < 22; ind++ ){

This initializes the minimum index to the current index

         int min = ind;

This iterates from current index to the last index of the array

         for (int k=ind+1; k < 23; k++ )

This compares the current array element with another

         if (my_array[k].compareTo(my_array[min] ) < 0 ){ min = k;  }

If the next array element is smaller than the current, the elements are swapped

<em>          String temp = my_array[ind];</em>

<em>          my_array[ind] = my_array[min];</em>

<em>          my_array[min] = temp;    }</em>

This iterates through the sorted array and print each array element

   for (int j=0; j < 23; j++){   System.out.print(my_array[j]+" ");}

    }

The main begins here

public static void main(String[] args) {

 Scanner input = new Scanner(System.in);

This declares the array

 String [] myarray = new String [23];

This gets input for the array elements

 for(int i= 0;i<23;i++){ myarray[i] = input.nextLine();  }

This prints the header Before sort

 System.out.print("Before sort: ");

This iterates through the array elements and print them unsorted

 for ( int j=0; j < 23; j++ ){        System.out.print(myarray[j]+" ");    }

This calls the function to sort the array

 SelectionSorter(myarray);

}

}

3 0
3 years ago
Select the correct answer.
IrinaK [193]
The answer is the letter (D)
4 0
3 years ago
Which of the following is typically an advantage of configuring your own hosting server over using an ISP or a cloud service pro
Inessa [10]

Answer:

D that's the answer it has to be

5 0
4 years ago
Other questions:
  • Assume the variable date has been set to a string value of the form mm/dd/yyyy, for example 09/08/2010. (Actual numbers would ap
    8·1 answer
  • Shelby likes to play video games on an old Atari video game system. No matter how old the cartridge, when she inserts it into th
    14·2 answers
  • What is the answer to this?
    12·1 answer
  • The seven basic internal components found in a computer tower
    9·1 answer
  • Which of the following is an automated or manual file that stores information about data elements and data characteristics such
    6·1 answer
  • You have an email that you are sending to a friend. You want to ensure it retains its integrity during transit, so you decide to
    5·1 answer
  • What is computer science
    6·2 answers
  • PLEASE HELP I WILL GIVE BRAINLIEST!!
    8·1 answer
  • Write a script that inputs a line of encrypted text and a distance value and outputs plaintext using a Caesar cipher. The script
    11·1 answer
  • A is a program for editing,rearranging and storing text
    13·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!