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
trasher [3.6K]
3 years ago
5

Write bash script which takes array as an input of size 10 bind its even indexes to accept even values and odd indexes to accept

odd numbers only. Print invalid input if given input is not valid.
Computers and Technology
1 answer:
jenyasd209 [6]3 years ago
6 0

Answer:

Bash script which takes array as an input of size 10 bind its even indexes to accept even values and odd indexes to accept odd numbers only is explained below in detail.

Explanation:

Even digits at an even table and odd digits at an odd table

Given an array of size n comprising an equal number of odd and even digits. The difficulty is to manage the numbers in such an approach that all the even digits get the even table and odd digits get the odd table. The necessitated auxiliary space is O(1).

Examples :

Input : arr[] = {8, 5, 1, 12, 6, 3}

Output : 3 6 1 12 5 8

Input : arr[] = {7, 9, 10, 19, 13, 18, 21, 20, 4, 14}

Output : 18 9 10 19 20 7 14 13 4 21

You might be interested in
I can't find my grandson someone help
Artemon [7]

Answer:

i'm right here

Explanation:

grandma

8 0
2 years ago
Read 2 more answers
3 uses of a computer ​
GenaCL600 [577]

Answer:

online bills payment

watching movies or shows

home tutoring

3 0
2 years ago
Read 2 more answers
What are the five layers in the internet protocol stack? What are the principal responsibilities of each of these lay?
mariarad [96]

Solution:

The five Layers in Internet protocol stack are:

1.Application Layer  

2.Transport Layer  

3.Network Layer  

4.Link Layer  

5.Physical Layer  

The principal responsibilities of these layers are as follows:

1.Application Layer •Applications with appropriate requirement for user.  

•It is reserved for network applications and their application protocols such as HTTP, SMTP, and FTP etc.  

•Its protocol uses transport layer protocols for establishing host-to-host connection.  

2.Transport Layer  

•It is responsible for End-to-Communication  

•Transport layer transports messages from application layer between client and server of application  

•It uses two protocol for transporting messages: TCP and UDP.TCP provides reliable connection oriented services, while UDP provides connectionless service  

3.Network Layer  

•Network Layer moves packets from one host to destination.

•It has two principal component:IP protocol:-It defines the datagrams and decide how the end system and router will work Routing protocols: these protocols decide the routing path between source and destination. 4.Link Layer  

•It is responsible for link-level communication  

•Link layer receives the data gram from network layer at each node and delivers it to next node, the next node passes the datagram to network layer.so This layer moves entire frames from one network element to adjacent one.

•The service provided by link layer is protocol dependent

5.Physical Layer  

•It provides Physical media

•At each node, it moves individual bits of frames to next node.  


7 0
2 years ago
17. Write a SELECT query for the palateE4 database that produces a result grid listing paintName, and a count of the occurrences
GaryK [48]

Answer:

SELECT paintname, COUNT(paintname) as count_paintname

FROM paint

GROUP BY paintname HAVING COUNT(paintname) > 2

ORDER BY paintname

Explanation:

The structured query language or SQL statement returns two columns of paintname and the count of the distinct paint names in the paint table with rows of grouped paint names greater than two and in the ascending order of the names.

4 0
2 years ago
Which of these lights is NOT part of the standard three-point lighting setup?
Contact [7]

Answer:

i believe background lighting

8 0
2 years ago
Other questions:
  • What feature could you use to automatically shade cells containing a negative value in red?
    7·2 answers
  • The TabIndex value assigned to a text box's identifying label must be _______________ for the text box's access key to work corr
    14·1 answer
  • What type of firewall works on the Session layer that creates a connection and allows packets to flow between the two hosts with
    8·1 answer
  • Match the characteristics to the mobile operating system that it describes.
    6·1 answer
  • Need answer ASAP
    8·2 answers
  • 1.
    7·1 answer
  • Hardware is found outside the system unit.​
    13·1 answer
  • Which part of project management considers if employees will work at home or in the office?
    10·2 answers
  • Write a 5 – 7+ sentence paragraph about Thanksgiving that DOES NOT use the letter “t.”
    10·1 answer
  • EDI, ________, smart cards, and digital certificates are designed to support safe and secure online transactions.
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!