Precedence and Associativity arithmetic operators - PowerPoint PPT Presentation

1 / 1
About This Presentation
Title:

Precedence and Associativity arithmetic operators

Description:

Ans: X=17-(2*8) , X=1. Y = 17 - 2 - 8? Ans: Y = (17-2)-8, Y=7 ... then use parentheses in your code! (write code for forgetful humans, not perfect machines) ... – PowerPoint PPT presentation

Number of Views:113
Avg rating:3.0/5.0
Slides: 2
Provided by: jack195
Category:

less

Transcript and Presenter's Notes

Title: Precedence and Associativity arithmetic operators


1
Precedence and Associativity(arithmetic
operators)
  • Examples
  • X 17 - 2 8 ? Ans X17-(28) , X1
  • Y 17 - 2 - 8? Ans Y (17-2)-8, Y7
  • Z 10 9 ((8 7) 6) 5 4 3 2 1 ?

Not sure? Confused? then use parentheses in your
code! (write code for forgetful humans, not
perfect machines)
Write a Comment
User Comments (0)
About PowerShow.com