c++ quizz!
•
16 Oct 2011, 11:07
•
Journals
Which of the following are not C++ expressions, and why?
1) 1*(2*3)
2) a=(b=5)
3) 1=a
4) (a=1)
5) (a=5)*(b=7)
6) (1
7) (a=b)*(b=5)
8) (a*3)=(b*5)
1) 1*(2*3)
2) a=(b=5)
3) 1=a
4) (a=1)
5) (a=5)*(b=7)
6) (1
7) (a=b)*(b=5)
8) (a*3)=(b*5)
because it has to be a = 1 , value has to be on right side?
a+b=c
trolled hard ;D
3) - afaik, number cant be a variable (variable name can contain number but cant start with one
6) - no right parenthesis = syntax error
8) - left side of assignment cannot be an expression, has to be variable
you know sql, mysql, c++ etc
everything i currently study
In my spare time however, I am involving myself into web technologies, namely PHP for server side (got some experience with J2EE too, but for I use PHP for convenience), MySQL (its just one of many SQL implementations, there are many more like MSSQL, Oracle, PostgreSQL...) for databases, and Javascript (+jQuery) for client-side scripting.
all in all, school wont give you much, if you want to know something you gotta learn by yourself :P
If yes,plz go hook with ET SDK:D
So you can tell me how to make parachuting spawning in ET.Since my head can't handle it...
This is what a Codey said to me:
But my mind can't think it out:S
But, from what I read it seems to be simple indeed (coding wise). You just need that flag (as that guy is saying), for example you name it parachute. If parachute is 0, player is treated normaly (normal gravity, normal movement physics, normal aiming), when its parachute=1 then you can actually change some settings (as you can read in that guys response). If client recognizes its actually with parachute on (by receiving parachute flag with value 1), then you change players gravity so he wont get hurt when landing + to also fall down slower + you can change some other settings, like bigger spread, limited movement (you cant really strafe with parachute or use sprint or I dont what else can be done), limit crosshair movement (like when you have mg, you cant turn around, same would go to guy with parachute on) etc etc. But I cant give you the code itself since I have no idea of how it looks line in ETs source code.
Hope this will give you better perspective on how it can be done.
Example: a=(b=5)
- If a is an integer then a and b will both be 5
- If a is a boolean then its a syntax error and should be a = (b==5)
3) 1=a
cannot use a number as variable so that wont work
6) (1
syntax error
8) (a*3)=(b*5)
will only work if you're trying to compare values in a test, rather than assigning a value. So it should be (a*3)==(b*5)
(:
are you familiar with OO Programming?
edit: just googled Eiffel... wtf syntax! :D