ASCII Encode

Lab 21- Encode a character
Content

Lab 21

Create a program takes a single character and encodes it. Ask the user for a character, the mulitplier and the adder. You will use this logic in project 5.



Example (keyboard input shown in bold):

Enter in a character

D

What is your multiplier?

3

What is your adder?

2

Encrytped: 206

so i have this lab but im totally lost can anyone give me links to see or start me off atleast please .
Read this. There's actually an example in there that is similar to your problem in it.

http://www.cplusplus.com/doc/tutorial/basic_io/

Remember, you want to input a character (type char) and 2 integers (type int).

Also remember that a char is a type of int (see http://www.cplusplus.com/doc/tutorial/variables/). After you read in the char, you can do all of the adding and multiplying you want to with it.
Topic archived. No new replies allowed.