From a2226f05a2154a1a7d686e5042f3e733357c63d8 Mon Sep 17 00:00:00 2001 From: Davis Kim Date: Sun, 10 Aug 2014 01:37:55 -0700 Subject: [PATCH] Add 'n' to function signature in #1 and 2 in complexityAnalysis.js Makes it more obvious that n is an input --- complexityAnalysis.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/complexityAnalysis.js b/complexityAnalysis.js index a9835eb..c1602e0 100644 --- a/complexityAnalysis.js +++ b/complexityAnalysis.js @@ -9,7 +9,7 @@ // --------------- Problem 1 --------------- -var doSomething = function(){ +var doSomething = function(n){ for(var i = 0; i < n; i++){ // do something here } @@ -25,7 +25,7 @@ var doSomething = function(){ // --------------- Problem 2 --------------- -var nestedLoops = function(){ +var nestedLoops = function(n){ for(var i = 0; i < n; i++){ for(var j = 0; j < n; j++){ // do something