It's UWAweek 42 (2nd semester, week 12)

help2002

This forum is provided to promote discussion amongst students enrolled in CITS2002 Systems Programming.
Please consider offering answers and suggestions to help other students! And if you fix a problem by following a suggestion here, it would be great if other interested students could see a short "Great, fixed it!"  followup message.
Displaying selected article
Showing 1 of 738 articles.
Currently 74 other people reading this forum.


 UWA week 37 (2nd semester, week 7) ↓
SVG not supported

Login to reply

👍?
helpful
10:38pm Fri 13th Sep, ANONYMOUS

This assumption was based off 'you cannot introduce a new function if its name is already used as a variable's name, or introduce a new variable if its name is already used as a function's name.' from https://secure.csse.uwa.edu.au/run/help2002?p=np&opt=U151 and 'a function's parameters and any other identifiers used in a function body are local to that function, and become unavailable when the function's execution completes'.

I must've misunderstood the meaning of 'becomes unavailable', is the correct rules that only function identifiers must be wholly unique, variables can be reassigned within their scope, and any local identifiers (function parameters + identifiers used in a function body) can be assigned/used as 'new' variables outside of their scope?

Thank you for all of the help!

The University of Western Australia

Computer Science and Software Engineering

CRICOS Code: 00126G
Written by [email protected]
Powered by history
Feedback always welcome - it makes our software better!
Last modified  8:08AM Aug 25 2024
Privacy policy