how do I get width from the beginning of the new line so 'Additional' aligns right under 'For'?
char choice;
cout<<"Package A: For $39.99 per month, 4 gigabytes are provided.\n"
<<setw(10)<<"Additional data costs $10 per gigabytes.";
return 0;
how do I get width from the beginning of the new line so 'Additional' aligns right under 'For'?
char choice;
cout<<"Package A: For $39.99 per month, 4 gigabytes are provided.\n"
<<setw(10)<<"Additional data costs $10 per gigabytes.";
return 0;
Copyright © 2021 Jogjafile Inc.
You can output empty string with width you desire. Like that: