answer.
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
frozen [14]
2 years ago
9

Add the following functions to the code:

Computers and Technology
1 answer:
artcher [175]2 years ago
7 0

Answer:

See explaination

Explanation:

#include <stdio.h>

#include <string.h>

#include <stdlib.h>

void oddsOnly(char* str)

{

int i;

for (i = 0;i < strlen(str);i++)

{

if(i%2 != 0)

{

str[i/2] = str[i];

}

}

str[i/2] = '\0';

}

char* mySubstring(char* string ,int beginIndex,int endIndex)

{

char* new_string = malloc(endIndex- beginIndex);

for (int i = beginIndex ;i < endIndex;i++)

{

new_string[i -beginIndex] = string[i];

}

new_string[endIndex] = '\0';

return new_string;

}

int main(void)

{

char str[] = "hello there";

oddsOnly(str);

char* str1 = mySubstring("smiles",1,5);

printf("%s\n",str);

printf("%s\n",str1);

}

You might be interested in
given the numerical value 1010101.11, which of the following number systems is most likely represented.
nasty-shy [4]

Answer:

u have to give me more points

Explanation:

sorry

7 0
2 years ago
What happened if the offshore team members are not able to participate in the iterations demo due to timezone/infrastructure iss
UkoKoshka [18]

What happened if the offshore team members are not able to participate in the iterations demo due to timezone/infrastructure issues-(c) No Major issue. Since offshore lead and onsite members participate in the demo with the product owner, they can cascade the feedback back to the offshore members.

Explanation:

<u>No Major issue. Since offshore lead and onsite members participate in the demo with the product owner, they can cascade the feedback back to the offshore members.</u>

From the above statement it is clear that in case the offshore team members are not able to participate in the demo with the product owner due to timezone/infrastructure issues it want be a big issue since the onsite members of the team will participate in the demo and they can give all the valuable knowledge and feedback to the offshore members.As they all are part of the very same team

<u>Hence the option(3) is the correct option</u>

4 0
2 years ago
Select the described workplace culture from the drop-down menu.
Vilka [71]

Answer:

  • Adaptive
  • Consistency-oriented
  • Achievement-based
  • Involvement-oriented

Explanation:

Adaptive Consistency-oriented workplace cultures emphasizes reacting quickly to change.

Consistency-oriented workplace cultures emphasizes everyone being in agreement.

Achievement-based Consistency-oriented workplace cultures emphasizes accomplishing goals.

Involvement-oriented Achievement-based workplace cultures emphasize development of new skills.

7 0
2 years ago
Read 2 more answers
The bit width of the LRU counter for a 32 KB 16-way set associative cache with 32 Byte line size is
Maksim231197 [3]

Answer:

your answer would be A

Explanation:

3 0
2 years ago
c++ Consider this data sequence: "3 11 5 5 5 2 4 6 6 7 3 -8". Any value that is the same as the immediately preceding value is c
Ksivusya [100]

<u>Answer:</u>

<em>int fNumber,scndNumber = -1,  </em>

<em>dup = 0; </em>

<em>do { </em>

<em>cin >> fNumber; </em>

<em>if ( scndNumber == -1) { </em>

<em>scndNumber = fNumber; </em>

<em>} </em>

<em>else { </em>

<em>if ( scndNumber == fNumber ) </em>

<em>duplicates++; </em>

<em>else </em>

<em>scndNumber = fNumber; </em>

<em>} </em>

<em>} while(fNumber > 0 );  </em>

<em>cout << dup; </em>

<u>Explanation:</u>

Here three variables are declared to hold the first number which is used obtain all the inputs given by the user, second number to hold the value of <em>last encountered number and “dup” variable to count the number of duplicate values.</em>

<em>“Do-while”</em> loop help us to get the input check whether it is same as previous input if yes then it <em>adds to the duplicate</em> value otherwise the new previous value if stored.

4 0
2 years ago
Read 2 more answers
Other questions:
  • Suppose you define a java class as follows: public class test { } in order to compile this program, the source code should be st
    14·1 answer
  • A patient asks her doctor to send a copy of her records to another medical office. However, the records are not transmitted beca
    10·2 answers
  • Jail and prison officials may generally limit inmate rights when the limitations serve
    13·2 answers
  • Write a static method, getBigWords, that gets a single String parameter and returns an array whose elements are the words in the
    15·1 answer
  • Given a positive integer, output its complement number. The complement strategy is to flip the bits of its binary representation
    6·1 answer
  • Database management systems are expected to handle binary relationships but not unary and ternary relationships.'
    7·1 answer
  • Select which type of computer you would like to begin building, based on the needs of your new job: Frequent travel Maintaining
    7·1 answer
  • A computer never gets tired or bored while working for a long time .. ​
    6·1 answer
  • What temperature is most commonly used in autoclaves to sterilize growth media and other devices prior to experimentation
    9·1 answer
  • An e-commerce client is moving from on-premise, legacy systems to a cloud-based platform. During the transition, the client is a
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!