Вы находитесь на странице: 1из 2

Random Meeting

Wednesday, July 31, 2013 8:27 AM

Function name = File name --kapag function --make sure that function and its subfunctions are in the same folder Next meeting, August 2, will be MEx. :) 1. User-defined Functions Differentiate script files from function files. Know how to make function files & understand the syntax used in making function files Know how to make & use sub-functions 2. Recursion and Making Recursive Calls

BOSS >> Minion 1, 2

Declaring Functions 1. Create a new script in the editor. 2. Type the following exactly as it is. 3. Save the file Remarks: Check if output and input is defined. :D randi = random numbers. Ex. randi(6,1,2) 6 = range, 1 = 1 row, 2 = 2 column % - comments - 'pag nag-help, ito 'yung mga lalabas. :)) Try this: Function [A B C] = next3multiples(x) A = 2*x B = 3*x C = 4*x End Note: If you want multiple output, then put brackets. :) There is a possibility to make a function that: 1. Does not return anything 2. Return something without asking for anything

Вам также может понравиться