Can you please rewrite these cods for me in a simple way without the '/n' and '/t' , also show me the output of them.
1.
#includeusing namespace std;// THE main bodyint main(){char item1[20]="Fresh Milk", item2[20]="Apple", item3[20]="Bread",item4[20]="Coffee";float price1=1.0,price2=2.0,price3=0.8,price4=2.5,ST_VAT1=0.05,ST_VAT2=0.10,ST_VAT3=0.5,ST_VAT4=0.15;cout<"\t \\\"food="" stuff="" grocery="" shop\"\n\n";="" i="" used="" '/n'="" to="" make="" new="" lines="" and="" '/t'="" to="" space="" horizontally="" in="" your="">"\t>cout<"customer>"customer>cout<" item\t\tprice\t\tsales="" tax+="">">cout<>cout<><><><" omr\t\t="">"><><"\t\t\t>"\t\t\t><><">">cout<><><><" omr\t\t="">"><><"\t\t\t>"\t\t\t><><">">cout<><><><" omr\t\t="">"><><"\t\t\t>"\t\t\t><><">">cout<><><><" omr\t\t="">"><><"\t\t\t>"\t\t\t><><">">cout<>float total=price1+ST_VAT1+price2+ST_VAT2+price3+ST_VAT3+price4+ST_VAT4;cout<><" gross="" bill-----------="">"><><">">cout<><" discount------------="">">cout<><" net="" bill------------="">"><><">">;return 0;}2.#includeusing namespace std;// the main bodyint main(){std::string item[10],name;int n;float price[10],ST_VAT[10],tax[10],total=0.0,Net;cout<"enter the="" number="" of="" items="" that="" should="" be="" atleast="" 5="" :="">"enter>cin>>n;cout<"enter the="" customer's="" name="">"enter>cin>>name;for(int i=1;i<>{ std::cout<"\nenter the="" item="">"\nenter>>name>>price[i]>>ST_VAT[i];tax[i]=price[i]+ST_VAT[i];total=total+tax[i];}Net=total-0.05*total;cout<"\t \\\"food="" stuff="" grocery="">"\t>cout<"customer>"customer><><>cout<" item\t\tprice\t\tsales="" tax+="">">cout<>for(int i=1;i<>cout<><><><" omr\t\t="">"><><"\t\t\t>"\t\t\t><><">">cout<>cout<><" gross="" bill-----------="">"><><">">cout<><" discount------------="">">cout<><" net="" bill------------="">"><><">">return 0;}
2.
#includeusing namespace std;// the main bodyint main(){std::string item[10],name;int n;float price[10],ST_VAT[10],tax[10],total=0.0,Net;cout<"enter the="" number="" of="" items="" that="" should="" be="" atleast="" 5="" :="">"enter>cin>>n;cout<"enter the="" customer's="" name="">"enter>cin>>name;for(int i=1;i<>{ std::cout<"\nenter the="" item="">"\nenter>>name>>price[i]>>ST_VAT[i];tax[i]=price[i]+ST_VAT[i];total=total+tax[i];}Net=total-0.05*total;cout<"\t \\\"food="" stuff="" grocery="">"\t>cout<"customer>"customer><><>cout<" item\t\tprice\t\tsales="" tax+="">">cout<>for(int i=1;i<>cout<><><><" omr\t\t="">"><><"\t\t\t>"\t\t\t><><">">cout<>cout<><" gross="" bill-----------="">"><><">">cout<><" discount------------="">">cout<><" net="" bill------------="">"><><">">return 0;}
Already registered? Login
Not Account? Sign up
Enter your email address to reset your password
Back to Login? Click here