Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6109117
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T14:22:09+00:00 2026-05-23T14:22:09+00:00

void main() { int numTickets; float discount; float total = 0.0; int numKids =

  • 0
void main()
{
    int numTickets;
    float discount;
    float total = 0.0;
    int numKids = 0;
    float ticketPrice = 19.00;
    printf("Enter number of tickets: ");
    scanf("%d", &numTickets);
 if (numTickets > 10)
 {
   discount = 0.15;
 }
 else
 {
   discount = 0.0;
 }
   printf("Enter number of children: ");
   scanf("%d", &numKids);
   total = numKids*ticketPrice/2.0 + (numTickets – numKids)*ticketPrice;
   total = total*(1.0 – discount);
   printf("Total = %.2f \n", total);
}

basically, im helping my cousin study and one of the questions is to draw a flowchart for that. the problem is iv forgotten everything i ever knew about flowcharts! Is there a standard for the variable declerations at the top? I can make up the rest of it actually, just not sure how to start em anymore!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T14:22:09+00:00Added an answer on May 23, 2026 at 2:22 pm

    Regular assignments (like your variable initialisations) should appear in a normal rectangle (like those in http://upload.wikimedia.org/wikipedia/commons/d/d6/FlowchartExample.png).

    Remember that IO (like your printf/scanf statements) should be in parallelograms, and conditional branches in diamonds.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I came across this code: #include<stdio.h> void main() { int x; float t; scanf(%f,&t);
int main(void) { char tmp, arr[100]; int i, k; printf(Enter a string: ); scanf_s(%s,
consider the code #include<stdio.h> int main(void) { char* a; scanf(%s,a);//&a and &a[0] give same
#include <stdio.h> void main() { int p[]={0,1,2,3,4}; int *a[]={p,p+1,p+2,p+3,p+4}; printf(%u %u %u,a,*a,*(*a)); } What
If I type the following void main(int blah, and then press enter, I want
void main(){ int i,k; char* p; int j; printf(address of i is %d \naddress
#include<stdio.h> int fact(int i); void main() { int j; j=fact(4); printf(%d,j); } int fact(int
#include <stdio.h> #include <conio.H> void main() { int a,b,c,d,e,f,g,i,h; float p; char A[10]; clrscr();
Anybody please elaborate these error:- void main() { int a=5, b=60, func(); printf(\nI am
import std.stdio; void main(){ int n; while(readf("%d", &n)){ if(n == 11) break; writeln(n); }

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.