Question: ***C++*** I am writing a program that will allow the user to repackage their liquid product by calculating the size of the item in order

***C++***

I am writing a program that will allow the user to repackage their liquid product by calculating the size of the item in order to maintain the same volume. I continue to get the errors "c++ forbids comparison between pointer and integer" or "warning: multi-character constant." I realize this is because I have declared repack_method as a char but the string function is not working (even when I change to double quotes and declare strings, that is when I encounter the pointer/integer error). I suspect I need to use the cctype library but am unsure how. How do I fix this?

***C++*** I am writing a program that will allow the user torepackage their liquid product by calculating the size of the item in

#include #include #include #include #include using namespace std; int main () //declare variables float ounces fluid; char repack method; char cube method [5]-'c', 'u', 'b','e', '10' char can method [4] -'C', 'a', 'n', '10'y char ballmethod [5]= {'b', 'a', '1','1','\0'); - cout ounces fluid; //read in user input cout ouncesfluid

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!