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
crimeas [40]
2 years ago
7

8. Given the array String[] words, which already contains 1 or more values, write a block of code which counts and returns the n

umber of words which start with the letter k
Computers and Technology
1 answer:
Vikentia [17]2 years ago
7 0

Answer:

Following are the code to this question:

public class Main//defining a class

{

public static void main(String[] arg)//defining main method

{

  String[] words={"Key","day", "Know", "kind"};//defining array of String words

  int x=0;//defining integer variable for count value

  for(int i=0;i<words.length;i++)//defining for loop for count value

  {

 if(words[i].startsWith("k")||words[i].startsWith("K"))//use if block to check word start from k

  x=x+1;//increment the value of x

  }

System.out.print("The number of letters which starts from k is: "+ x);//print value with message

}

}

Output:

The number of letters which starts from k is: 3

Explanation:

In this code, inside the main method an array of String "words" is defined that hold a value, and in the next step an integer variable "x" is defined, which is used to count the letters, which starts from k.

For this, a for loop is used that counts the value and in this an, if block is defined that uses the "startsWith" method to check the value and increment the value of x and at the last, it prints its value.

You might be interested in
Joe, a user, wants his desktop RAID configured to allow the fastest speed and the most storage capacity. His desktop has three h
kirill115 [55]

Answer:

A. 0

Explanation:

The technician should configure the RAID 0 for Joe.

RAID 0 also referred to as the striped volume or stripe set is configured to allow the fastest speed and the most storage capacity by splitting data evenly across multiple (at least two) disks, without redundancy and parity information.

Also, RAID 0 isn't fault tolerant, as failure of one drive will cause the entire array to fail thereby causing total data loss.

7 0
3 years ago
Whereas enterprise network convergence focuses on the consolidation of traditionally distinct voice, video, and data communicati
Vinil7 [7]

Answer: Unified communication

Explanation: Unified communication is the communication technique in which merges various communication routines into a individual business.It works as the phone system which helps in increment of productivity in an organizational business.

The unifying of voice,data/information,video etc is done for optimizing and improving the business that also results in  faster communication rates, secure communication etc.

4 0
3 years ago
the impact of the global digital divide. According to the authors, countries that lag behind the rest of the world’s ICT capabil
kvasek [131]

Answer:

hi

Explanation:

5 0
2 years ago
A government agency is getting rid of older workstations. The agency will donate these workstations, along with other excess com
algol [13]

The simplest ways are being used to help eliminate the previously stored data, by deleting hard disc storage facilities with the same data wherever that used a sequence of all zeros.

<h3>What is a hard disc?</h3>

The "DoD Standard" is a term used during the data sanitizing industry and refers to DoD 5220.22-M, and the further discussion can be defined as follows:

The simplest ways are being used to help eliminate the previously stored data, by deleting hard disc storage facilities with the same data wherever that used a sequence of all zeros.

The sparging eliminates statistics to entirely delete the gravitational flux from electronic media.

Hard drives as well as other data storage devices, for example, computer tapes, retain magnetic data.

It could no longer be seen as storage after a disk is degaussed.

Therefore, the final answer is "Using the DoD 5220.22-M method and  Degauss media with a magnet".

Learn more about hard disc at:

brainly.com/question/13329582

#SPJ1

3 0
2 years ago
Which of the following is a professional organization in the field of IT? Society for the Prevention of Cruelty to Animals (SPCA
Lelu [443]
(IEEE) Is the obvious answer ; no harshness meant in any way
7 0
3 years ago
Read 2 more answers
Other questions:
  • Ted is a fashion designer. Where is he most likely to work
    9·1 answer
  • Which statement is true about parity in RAM?
    11·1 answer
  • The device used to connect a network to the internet is called a
    7·1 answer
  • Rint "Censored" if userInput contains the word "darn", else print userInput. End with newline.
    11·1 answer
  • Of the following which would be the best data representation for this puzzle in a puzzle class?
    6·1 answer
  • Create a function (prob3_6) that will do the following: Input a positive scalar integer x. If x is odd, multiply it by 3 and add
    15·1 answer
  • What is the difference between a try block and a try statement? Group of answer choices There is no difference; the terms can be
    6·1 answer
  • The term packet is used fairly generically to refer to protocol data unit (PDU). There are PDU equivalent names in the different
    15·1 answer
  • What is the output of this program?
    10·2 answers
  • What are your thoughts on the last nintendo direct
    5·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!