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
TiliK225 [7]
3 years ago
10

Consider the following code segment, which is intended to display "cat".

Computers and Technology
2 answers:
mrs_skeptik [129]3 years ago
8 0

Answer:

Replace missing expression with:

keyboard[2][2].toLowerCase()+keyboard[1][0]+keyboard[0][4]

Explanation:

Given

The above code segment

Required

Which code displays "Cat"

First, we need to identify the location of C, a and t in the array

C \to keyboard[2][2] i.e. C is at the 2nd row index and 2nd column index

a \to keyboard[1][0] i.e. a is at the 1st row index and 0 column index

t \to keyboard[0][4] i.e. t is at the 0 row index and 4th column index

Next convert C to lowercase.

This is done using: toLowerCase() method.

So, we have: keyboard[2][2].toLowerCase()

Next, we concatenate each of the above.

i.e. keyboard[2][2].toLowerCase()+keyboard[1][0]+keyboard[0][4]

Lastly, the statement is printed:

<em>System.out.println(keyboard[2][2].toLowerCase()+keyboard[1][0]+keyboard[0][4]);</em>

erastovalidia [21]3 years ago
6 0

Answer:

Explanation: can you include a picture?

You might be interested in
What are the 3 examples of numeral systems
Murrr4er [49]

A digit is a single symbol used to make numerals. 0, 1, 2, 3, 4, 5, 6, 7, 8 and 9 are the ten digits we use in everyday numerals. Example: The numeral 153 is made up of 3 digits ("1", "5" and "3").

6 0
3 years ago
Implement a container class Stat that stores a sequence of numbers and provides statistical information about the numbers. It su
olga2289 [7]

Answer:

See explaination

Explanation:

Definition of Class 1:

class Stat:

def __init__(self, li):

self.li = li

def add(self, value):

self.li.append(value)

def __len__(self):

return len(self.li)

def min(self):

try:

return min(self.li)

except:

return "EmptyStatError: empty Stat does not have a min"

def max(self):

try:

return max(self.li)

except:

return "EmptyStatError: empty Stat does not have a max"

def sum(self):

return sum(self.li)

def mean(self):

try:

return float(sum(self.li))/float(len(self.li))

except:

return "EmptyStatError: empty Stat does not have a mean"

def __getitem__(self):

return self.li

def clear(self):

del self.li[:]

Definition of Class 2:

class intlist:

def __init__(self, li):

self.li = li

def append(self, value):

if type(value) == int:

self.li.append(value)

else:

print "NotIntError: Input is not an Integer."

def insert(self, index,value):

if type(value) == int:

self.li.insert(index, value)

else:

print "NotIntError: Input is not an Integer."

def extend(self, value):

i = 0

for temp in value:

if type(temp) == int:

i = i

else:

i = i+1

if i==0:

self.li.extend(value)

else:

print "NotIntError: Input is not an Integer."

def __setitem__(self, index, value):

self.insert(index, value)

def __getitem__(self, index):

return self.li[index]

def odds(self):

lis = []

for temp in self.li:

if temp%2 == 1:

lis.append(temp)

return lis

def evens(self):

lis = []

for temp in self.li:

if temp%2 == 0:

lis.append(temp)

return lis

Class 1 call:

s = Stat([])

s.add(2.5)

s.add(4.7)

s.add(78.2)

print len(s)

print s.min()

print s.max()

print s.sum()

print s.mean()

print s.li

s.clear()

print s.li

print len(s)

print s.min()

print s.max()

print s.mean()

print s.sum()

Class 2 call:

intl = intlist([])

print intl.li

intl = intlist([1,2,3])

print intl.li

intl.append(5)

print intl.li

intl.insert(1,99)

print intl.li

intl.extend([22,44,66])

print intl.li

print intl.odds()

print intl.evens()

print intl.li

intl[2] = -12

print intl[4]

6 0
4 years ago
The Loanable Funds Market is built very similar to the Supply &amp; Demand Model. The Loanable Funds Market relates ____________
lawyer [7]
A should be the right answer
3 0
3 years ago
Assume that the variable myString refers to a string. Write a code segment that uses a loop to print the characters of the strin
Svetach [21]

Answer:

hi my name is antonette Jane S pascua please help me my question thank you for your answer

5 0
3 years ago
What are preconceptions?
anastassius [24]
An idea or statement  that you had previously or earlier.

6 0
4 years ago
Read 2 more answers
Other questions:
  • Three healthcare firms jointly own and share the same cloud resources to meet their computing needs. Which cloud model does this
    15·1 answer
  • A collection of related files that serves as a foundation for retrieving information is a: byte
    12·1 answer
  • Suppose that TCP's current estimated values for the round trip time (estimatedRTT) and deviation in the RTT (DevRTT) are 400 mse
    9·1 answer
  • Rapid development programming languages eliminate the possibility of having bugs in code. True or False
    8·1 answer
  • Next, Jamal wants to copy text from a Word document to the slide he just added. He outlines the steps to complete his task. Step
    15·2 answers
  • anyone here done intro to tech course on edgenuity yet? I failed the first unit test twice and it's prob gonna be a third if i r
    14·2 answers
  • _____ are labels for data, while _____ tie values together into one entity.
    15·1 answer
  • These statements describe guidelines for the use of tables in presentations.
    9·2 answers
  • Computers were originally developed to accomplish various tasks in relative isolation, very different from the collaboration and
    14·1 answer
  • When scriptwriters are writing scripts, why do they have to write them in accordance with industry standards?
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!