I need to erase a printed character in a new line from the end. That is if the statement is printf("C++") I need to erase those 2 "++" printed and get the output "C".
printf("hello"); printf("\rbye"); Using the above escape sequence '\r', replaces it only from the printed line beginning to get the output 'byelo', how to do it from the end to get 'hebye'?