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
snow_lady [41]
2 years ago
9

Write a program that takes a string as an input. If the string entered is equal to

Computers and Technology
1 answer:
Ivenika [448]2 years ago
3 0

The program could be written using a python script.

<h3>Python script on string operation</h3>

The program takes a string as an input. First, declare a variable for the input:

var = str()

#The above code will ask for a string to be inputted

Next would be to condition the script in a particular direction using the 'if' statement. That is, a Boolean function.

if var ==('chicken'):

#The above code will compare the inputted string to the word 'chicken'.

  print("This is equal")

#The screen will display 'This is equal' if the inputted stringis the same as 'chicken'.

else:

  print("This is not equal")

#The screen will display "This is not equal" if the inputted string is not the same as 'chicken'.

In summary, the code goes thus:

var = str()

if var ==('chicken'):

   print("This is equal")

else:

   print("This is not equal")

More on python scripts can be found here: brainly.com/question/14378173

#SPJ1

You might be interested in
On a client/server network, which computer initiates the process of assigning an IP address through DHCP?
Vera_Pavlovna [14]

Answer:

The client

Explanation:

On a client/server network, THE CLIENT computer initiates the process of assigning an IP address through DHCP. This is because "The Client" computer will serve as the Domain controller in which other computers of the network can find. Hence, The Client computer initiates the process of assigning IP addresses through DHCP to achieve this.

Though, in some case. A user can manually assign the IP address to computer if it is not through DHCP

4 0
3 years ago
How do you use loops in code?
Keith_Richards [23]

Answer:

A loop in a computer program is an instruction that repeats until a specified condition is reached. In a loop structure, the loop asks a question. If the answer requires action, it is executed. ... A computer programmer who needs to use the same lines of code many times in a program can use a loop to save time

Explanation:

4 0
3 years ago
Assume you have an integer pointer variable named intpoint2. It contains the address 1e6f24. You execute intpoint2++. What does
Serjik [45]

Answer:

c)1e6f28

Explanation:

The integer pointer intpoint2 points to the address 1e6f24.On increasing the inpoint.The intpoint will point to next location and since we know that the memory taken by integers is 4bytes.So the pointer will move to the next location 4 bytes ahead.

1e6f24+4=1e6f28.

Hence the answer is option c.

8 0
2 years ago
Compare the time spent on each of the above operations, and describe your observations. If an operation is too fast, you may wan
Artist 52 [7]

Here's the complete question below that clarifies what you need to do

<u>Explanation</u>:

"In this task, we will study the performance of public-key algorithms. Please prepare a file ( message.txt) that contains a 16-byte message. Please also generate an 1024-bit RSA public/private key pair. Then, do the following:

1)Encrypt message.txt using the public key; save the the output in message_enc.txt.

2)Decrypt message_enc.txt using the private key.

3)Encrypt message.txt using a 128-bit AES key.

<em><u>Compare the time spent on each of the above operations, and describe your observations. If an operation is too fast, you may want to repeat it for many times, i.e., 5000 times, and then take an average.</u></em>

<em><u> After you finish the above exercise, you can now use OpenSSL's speed command to do such a benchmarking. Please describe whether your observations are similar to those from the outputs of the speed command?</u></em>

3 0
3 years ago
Write a conditional expression that assign the value 0 to a credits variable if it is less than 0; otherwise the value of the cr
Svetach [21]

Answer:

credits = (credits < 0) ? 0 : credits;

Explanation:

This is the ternary conditional operator.

6 0
3 years ago
Read 2 more answers
Other questions:
  • In which of the following is “y” not equal to 5 after execution? X is equal to 4.
    9·1 answer
  • Henry is studying the effects of deforestation along the slopes of hills and mountains. He wants to take a photo of a mountain s
    14·1 answer
  • You are designing a wireless network for a client. Your client needs the network to support a data rate of at least 54Mbps. In a
    11·1 answer
  • • What advantage does a circuit-switched network have over a packet-switched network? What advantages does TDM have over FDM in
    12·1 answer
  • Windows, Apple’s Mac OS, and Unix/Linux are just some of the most common what?
    7·2 answers
  • True or false.local and cloud backup differs in where the backup is saved
    15·2 answers
  • An example of software is a
    8·1 answer
  • Your friends are having difficulties with their computer setups. Can you suggest a way to help each friend?
    5·1 answer
  • Part of an algorithm which is repeated for fixed number of times is classified as.
    13·1 answer
  • You have a computer that runs on a windows 10 operating system and supports modern sleep. what will happen if you close the lid
    10·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!