재귀함수

JavaScript

[JavaScript] function(함수)

function(함수) function hello(){//hello함수 정의 alert("hello!") } hello()//hello함수 호출 //--------------------------------------------------- function hello(n){//매개변수,파라미터 alert("hello:"+n);//hello:3 } hello(3)//함수 호출(function call) //hello함수를 호출하면서 입력으로 3전달 //매개변수=매개체변수 //매개체=둘사이를 연결하는 ~어떤것 //--------------------------------------------------- function add(n1,n2){//매개변수 2개 설정 return n1+n2;//더한값 반환 //함..

Potato Ongsim
'재귀함수' 태그의 글 목록