HP Forums

Full Version: about output in HP 48G+
You're currently viewing a stripped down version of our content. View the full version with proper formatting.

I'm running a program to give an angle in degrees mins, and secs, with the characters, but i also keep getting C$ 10 before the angle. I also get the symbols for deg, min and sec. How do i get rid of C$ 10? thanks,

Jason,

Ah... by fixing your program. The C$ nnn is an alternate form of displaying a string, generally when you attempt to edit giant-sized strings. The nnn is the number of characters in the string.

What is the program? Try the [PRG][NXT] RUN DEBUG command and SST to see what's happening during execution.

Joe

Hi Jason;

The result you are getting is normal. It is refered to as a counted string. Normally you would not see the C$ unless you tried to edit the string. This occurs because the string contains double quotes. As an example;

If the display shows

""How Are You?""

that is with two double quotes at the beginning of the string and two double quotes at the end of the string, and you press the down arrow key to edit this string, you will see;

C$ 14 "How Are You?"

C$ means that it is a counted string, 14 is the length of the string and "How Are You?" is the string, with the double quotes. In your case I'll bet you are using double quotes to designate seconds, i.e. 51°13'34" as an example. Because of the double quotes this is converted into a counted string if you attempt to edit it. If you print or display this counted string it will print or display correctly, without the C$. You can also create a string which contains double quotes using this method. Press alpha alpha C$ nn and then the string, where nn is the length of the resultant string, not counting the automatic double quotes placed at the beginning and end of the string by the os. In fact any string can be created this way, although not as easily as simply entering the string. As an example;

C$ 24 This Is A Double Quote "

will result in this string

"This Is A Double Quote ""

on the display.

Hope this has answewred your question and has helped you.

Take care.

rdb.