CS 24000 Study Guide - Midterm Guide: Short Circuit

32 views3 pages

Document Summary

My string is a string constant of type (char *: there are no operations with string in java like hello + world , however, two consecutive string constants can be put together by the complier, hello. World is equivalent to: hello. world , so you can have multi-line strings like, char * class , cs240 \n , programming in c \n , the compiler will put both constants in a single string. Short-circuit && (and) and || (or) expression: e1 && e2 is the short circuit and expression, if e1 is false, e2 is not evaluated if(x && (i = y)) // then i=y is never evaluated: e1||e2 is the short circuit or expression, if e1 is true, then e2 is never evaluated if (x || (i=y)) Boolean and int: there is no boolean type, a 0 is false and anything different than 0 is true. Conditional expressions: e = (e1 ? e2 : e3) *conditional expression.

Get access

Grade+20% off
$8 USD/m$10 USD/m
Billed $96 USD annually
Grade+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
40 Verified Answers

Related Documents