chirilasrares5580 chirilasrares5580
  • 12-08-2019
  • Computers and Technology
contestada

The variable cp_arr has been declared as an array of 26 pointers to char. Allocate 26 character values, initialized to the letters 'A' through 'Z' and assign their pointers to the elements of cp_arr (in that order).

Respuesta :

flightbath flightbath
  • 16-08-2019

Answer:

void main(){

char*[] cp_arr= new char*[20];

char ch;

int i=0;

for(ch='A';ch<='Z';ch++){

*cp_arr[i]=ch;

i++;

}

}

Explanation:

we are taking a char array of pointers and iterating a loop to store A to Z values in that array in the mentioned order

Answer Link

Otras preguntas

a^2=-42+13a solve by factoring ?
Please help In the sequence below the first term is 2 and each term after the first is k times the preceding term where k is a constant. What is the value of th
It is estimated that light takes 10,000 years to travel the full distance across our galaxy. If light travels at 3.0 x 10^8m in 1 second then what is the distan
How do u write 0.0000000405 in scientific notation ?
Solve the equation for x∈Z -x² +8x -14 ≥ 0
How did the writings of John Locke and Baron de Montesquieu influence ideas about government in what became the United States?
What is a transformer?!?!
a pack of 12-8 ounce bottles of water costs $3.36.What is the unit cost per ounce of bottled water?$0.03 per ounce$0.04 per ounce$0.28 per bottle$0.42 per bottl
What is the scientific notation for 568 billion?
What is the scientific notation for 568 billion?