Skip to content
main-logo
  • +91 637-050-2482
  • santuitreturns@gmail.com
Menu
Menu
  • Home
  • Income Tax
    • Income From Salary
    • Profit or gain from Business/Profession.
    • Capital Gain
    • Income From Other Sources
    • 80C to 80U
    • TDS & TCS
    • ITR FORMS
  • International Taxation
    • Transfer Pricing
    • Non-Resident Taxation
    • Foreign Tax Credit (FTC)
    • Model Tax Convention
    • Base Erosion and Profit Shifting (BEPS)
  • GST
  • Accounting
  • MCQs
    • NEET
    • NEET QUIZ TEST
    • NEET PG MCQ’s
    • NEET PG QUIZ TEST
    • Civil Engineering
    • Mechanical Engineering MCQs
    • CHSL EXAM
      • Logical Reasoning
  • Others
    • Job Tips
  • CA Courses
    • CA Inter/IPCC

TOP 20+ MCQs on Infix to Postfix Conversion Data Structure with Answers

Posted on November 16, 2023

1. When an operand is read, which of the following is done?

a) It is placed on to the output
b) It is placed in operator stack
c) It is ignored
d) Operator stack is emptied

View Answer

Answer: a

Explanation: 

While converting an infix expression to a postfix expression, when an operand is read, it is placed on to the output. When an operator is read, it is placed in the operator stack.

2. What should be done when a left parenthesis ‘(‘ is encountered?

a) It is ignored
b) It is placed in the output
c) It is placed in the operator stack
d) The contents of the operator stack is emptied

View Answer

Answer: c

Explanation:

When a left parenthesis is encountered, it is placed on to the operator stack. When the corresponding right parenthesis is encountered, the stack is popped until the left parenthesis and remove both the parenthesis.

3. Which of the following is an infix expression?

a) (a+b)*(c+d)
b) ab+c*
c) +ab
d) abc+*

View Answer

Answer: a

Explanation:

(a+b)*(c+d) is an infix expression. +ab is a prefix expression and ab+c* is a postfix expression.

4. What is the time complexity of an infix to postfix conversion algorithm?

a) O(N log N)
b) O(N)
c) O(N2)
d) O(M log N)

View Answer

Answer: b

Explanation:

The time complexity of an infix to postfix expression conversion algorithm is mathematically found to be O(N).

5.What is the postfix expression for the corresponding infix expression? a+b*c+(d*e)

a) abc*+de*+
b) abc+*de*+
c) a+bc*de+*
d) abc*+(de)*+

View Answer

Answer: a

Explanation:

Using the infix to postfix expression conversion algorithm, the corresponding postfix expression is found to be abc*+de*+.

6. Parentheses are simply ignored in the conversion of infix to postfix expression.

a) True
b) False

View Answer

Answer: b

Explanation:

When a parenthesis is encountered, it is placed on the operator stack. When the corresponding parenthesis is encountered, the stack is popped until the other parenthesis is reached and they are discarded.

7. It is easier for a computer to process a postfix expression than an infix expression.

a) True
b) False

View Answer

Answer: a

Explanation:

Computers can easily process a postfix expression because a postfix expression keeps track of precedence of operators.

8. What is the postfix expression for the infix expression? a-b-c

a) -ab-c
b) ab – c –
c) – -abc
d) -ab-c

View Answer

Answer: b

Explanation:

The corresponding postfix expression for the given infix expression is found to be ab-c- and not abc- -.

 

9. What is the postfix expression for the following infix expression? a/b^c-d

a) abc^/d-
b) ab/cd^-
c) ab/^cd-
d) abcd^/-

View Answer

Answer: a

Explanation:

Using the infix to postfix conversion algorithm, the corresponding postfix expression for the infix expression is found to be abc^/d-.

10. Which of the following statement is incorrect with respect to infix to postfix conversion algorithm?

a) operand is always placed in the output
b) operator is placed in the stack when the stack operator has lower precedence
c) parenthesis are included in the output
d) higher and equal priority operators follow the same condition

View Answer

Answer: c

Explanation:

Parentheses are not included in the output. They are placed in the operator stack and then discarded.

11. In infix to postfix conversion algorithm, the operators are associated from?

a) right to left
b) left to right
c) centre to left
d) centre to right

View Answer

Answer: b

Explanation:

 In infix, prefix and postfix expressions, the operators are associated from left to right and not right to left.

12. What is the corresponding postfix expression for the given infix expression? a*(b+c)/d

a) ab*+cd/
b) ab+*cd/
c) abc*+/d
d) abc+*d/

View Answer

Answer: d

Explanation:

 Using the infix to postfix conversion algorithm, the corresponding postfix expression is obtained as abc+*d/.

13. What is the corresponding postfix expression for the given infix expression? a+(b*c(d/e^f)*g)*h)

a) ab*cdef/^*g-h+
b) abcdef^/*g*h*+
c) abcd*^ed/g*-h*+
d) abc*de^fg/*-*h+

View Answer

Answer: b

Explanation:

Using the infix to postfix expression conversion algorithm using stack, the corresponding postfix expression is found to be abcdef^/*g*h*+.

14. What is the correct postfix expression for the following expression? a+b*(c^d-e)^(f+g*h)-i

a) abc^de-fg+*^*+i-
b) abcde^-fg*+*^h*+i-
c) abcd^e-fgh*+^*+i-
d) ab^-dc*+ef^gh*+i-

View Answer

Answer: c

Explanation:

 The postfix expression for the given infix expression is found to be abcd^e-fgh*+^*+i- when we use infix to postfix conversion algorithm.

15. From the given Expression tree, identify the correct postfix expression from the list of options. The postfix expression is ab*cd-+ from the given Expression tree

a) ab*cd*+
b) ab*cd-+
c) abcd-*+
d) ab*+cd-

View Answer

Answer: b

Explanation:

From the given expression tree, the infix expression is found to be (a*b)+(c-d). Converting it to postfix, we get, ab*cd-+.

    You May Also Like...

  • Most Beautiful Gandahati Water Fall of Paralakhemundi District
  • DARINGBADI – KASHMIR OF ODISHA (HILL STATION)
  • Most Attactive Ludu Water Fall, Kandhamal
  • Top 10 Attractive Points Regarding Konark Sun Temple, Puri District
  • Know About Most Powerful Jagannath Temple, Puri
  • Top Story About Ghatgan Tarini Temple, Keonjhar District
  • Famous Rayagada Maa Majhighariani Temple [ Top Story]
  • 10 Simple Strategies to Build a Perfect Resume [Job Tips]

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Quick Links

  • Home
  • About Us
  • Privacy Policy
  • Terms of Use
  • Disclaimer
  • Contact Us

Categories

  • Income Tax
  • International Taxation
  • GST
  • MCQs
  • Others
  • CA Courses

Latest Posts

  • Five changes in ITR forms of FY 2024-25 (AY 2025-26)
  • Form 10-IEA: Option to Choose Old Tax Regime
  • What is Section 54EC of the Income Tax Act?
  • What is Section 54F of the Income Tax Act?
©2025 Online Solves. All rights Reserved | Developed by AlgoPage IT Solutions Pvt. Ltd.
We use cookies on our website to give you the most relevant experience by remembering your preferences and repeat visits. By clicking “Accept All”, you consent to the use of ALL the cookies. However, you may visit "Cookie Settings" to provide a controlled consent.
Cookie SettingsAccept All
Manage consent

Privacy Overview

This website uses cookies to improve your experience while you navigate through the website. Out of these, the cookies that are categorized as necessary are stored on your browser as they are essential for the working of basic functionalities of the website. We also use third-party cookies that help us analyze and understand how you use this website. These cookies will be stored in your browser only with your consent. You also have the option to opt-out of these cookies. But opting out of some of these cookies may affect your browsing experience.
Necessary
Always Enabled
Necessary cookies are absolutely essential for the website to function properly. These cookies ensure basic functionalities and security features of the website, anonymously.
CookieDurationDescription
cookielawinfo-checkbox-analytics11 monthsThis cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Analytics".
cookielawinfo-checkbox-functional11 monthsThe cookie is set by GDPR cookie consent to record the user consent for the cookies in the category "Functional".
cookielawinfo-checkbox-necessary11 monthsThis cookie is set by GDPR Cookie Consent plugin. The cookies is used to store the user consent for the cookies in the category "Necessary".
cookielawinfo-checkbox-others11 monthsThis cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Other.
cookielawinfo-checkbox-performance11 monthsThis cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Performance".
viewed_cookie_policy11 monthsThe cookie is set by the GDPR Cookie Consent plugin and is used to store whether or not user has consented to the use of cookies. It does not store any personal data.
Functional
Functional cookies help to perform certain functionalities like sharing the content of the website on social media platforms, collect feedbacks, and other third-party features.
Performance
Performance cookies are used to understand and analyze the key performance indexes of the website which helps in delivering a better user experience for the visitors.
Analytics
Analytical cookies are used to understand how visitors interact with the website. These cookies help provide information on metrics the number of visitors, bounce rate, traffic source, etc.
Advertisement
Advertisement cookies are used to provide visitors with relevant ads and marketing campaigns. These cookies track visitors across websites and collect information to provide customized ads.
Others
Other uncategorized cookies are those that are being analyzed and have not been classified into a category as yet.
SAVE & ACCEPT