Hi Naveen i am holding three best product based company offer only because of you!! i am claering all the interviews which are coming on my way no matter whther it is manual, automation, api, selenium, bdd, microservice, everything i am clearing in single shot...seriouly i dont have words to praise you..Thanks a lotttttt for evrything❤️❤️....Stay blessed forever!!!! If possible i definately need to meet and take blessings of you!!
@GreatStoriesTakeTime3 жыл бұрын
Cab you share me the API interview questions or from which site you prepared ??
@hemakeerthi57093 жыл бұрын
Can you guide us??? From where you have prepared and what to prepare?
@mahatheedandibhotla3 жыл бұрын
@@GreatStoriesTakeTime Dont prepare for interview learn the subject as a whole if u learn it you dont need interview questions at all
@prasannaprasy9503 жыл бұрын
Hi all i consantly followed naveen automation labs from past one year and consumed how much ever knowledge i could, that is the reason i am able to clear all the interviews now..if u r strong in subject u can answer any question coming at you!! All the best everyone!!👍
@yuvasrivanth3 жыл бұрын
@@prasannaprasy950 great both of you
@souvikchatterjee74003 жыл бұрын
Streams concept did not come to my mind. I solved this using recursion in one of my interviews. Thanks for sharing Naveen
@naveenautomationlabs3 жыл бұрын
All the best
@somnathsahoo55473 жыл бұрын
Do u get asked ?or run
@buttofthejoke3 жыл бұрын
forEach is literally a loop. And recursion is an obvious alternative to looping.
@ozrenbalic60513 жыл бұрын
@@buttofthejoke it isn't a loop, it is a higher order method. How it is implemented is irrelevant from the caller's point of view.
@buttofthejoke3 жыл бұрын
@@ozrenbalic6051 What? You mean forEach does not loop over each item? You can implement a forEach where it doesn't loop? can you give a quick sample? I need to know if my life was a lie. (or yours is)
@suman-majhi3 жыл бұрын
Underrated channel.... People love masala content, not quality content. Subscribed after watching such a quality content😊😊
@naveenautomationlabs3 жыл бұрын
Thank you so much 😀
@MerryEveryday3 жыл бұрын
I was about to sleep but the caption bugged me and I couldnt help myseld but watch this video. Thanks! Such simple tricks but we just need to remember it on time
@BhavyaTyagi163 жыл бұрын
That's what happened with me right now. 3:07 am. 😂
@mohammedayesh13783 жыл бұрын
same at 6:23am
@meyashtiwari3 жыл бұрын
ForEach is also a loop, using it kinda defeats the purpose of the question, right?
@AmitKumar-si3yd3 жыл бұрын
I agree, I don't think ForEach is a good solution if we can't use loop.
@user-id2nj2co1q3 жыл бұрын
Yeah, exactly what I was thinking. Then the loop just gets executed in some library code
@roopakbedekar32813 жыл бұрын
That is exactly what i thought when he wrote it. forEach also iterates for all the items in the list/array so its one or the same as a loop
@vrtex173 жыл бұрын
Not really, it's just a method that happens to have "loop" in it's name.
@simonmultiverse63493 жыл бұрын
@@vrtex17 ...and also happens to behave like a loop.
@k-ai-ros3 жыл бұрын
No loops, not recursion loop also... void printNumbersWithoutLoop() { BitSet bitSet = new BitSet(); bitSet.set(0, 101); String substring = bitSet.toString() .replaceAll("\\{|, |}", " "); System.out.println(substring); }
@aleksanderf46723 жыл бұрын
You speak the language of Gods.
@buthow9003 жыл бұрын
Replace all uses loops inside xD
@sunny-mx9ff3 жыл бұрын
how can we do this in C++?? like is there any way we can achieve the same task(printing 1-100) with same constraints(no loops or recursion) in C++???
@hezekiahbranch54613 жыл бұрын
Thought I'd share the recursive Python version if anyone was interested: def print_100(num): if num > 100: return else: print(num) return print_100(num + 1) print_100(1)
@atrumluminarium3 жыл бұрын
There's a one-liner way to do it in python using lambdas and conditional assignments if you exploit the fact that the arguments for the "or" keyword are executed in chronological order: print100 = lambda num: print(num) or print100(num+1) if num
@DJ-rf8kz3 жыл бұрын
@@atrumluminarium why does it check both conditions? i thought ‘or’ only chooses 1?
@atrumluminarium3 жыл бұрын
@@DJ-rf8kz it chooses only one if the first argument is "True" (I believe the technical term for this is short circuiting). However "print()" returns "None" which python interprets as "False" so it checks the second argument as well which in this case is the recursion
I was asked this question in Paytm first round....Thanks to you I write the code successfully and execute it by using a Recursive function.
@petribalanceisnice3 жыл бұрын
For real though, how is that without any loop? Recursive function feels like the definition of loop Edit: I mean "if" in this case just becomes another "while"
@kazedcat3 жыл бұрын
It acts like a loop but it is not a loop. At machine level recursive function manipulates the stack but a loop is just a simple branch instruction.
@angeldude1013 жыл бұрын
@@kazedcat Except many compilers are smarter than that and, if the recursion is written properly, will transform it into a loop that reuses its stack space.
@randomactsofgaming8453 жыл бұрын
The real question for me is why would you not just use a loop? I mean yea it’s an interesting challenge I guess, but we have developed loops specifically for these kinds of reasons. This is the equivalent of telling someone to try mowing their grass without using their lawnmower. If you’re going to teach someone somethings about programming teach them to use the tools available to them not to ignore those tools.
@kazedcat3 жыл бұрын
RandomActs OfGaming Part of programming is problem solving. This is just a toy problem to let people use the tools instead of just memorizing them. The value of this problem is it allow you to spot people who did not really understand programming.
@randomactsofgaming8453 жыл бұрын
@@kazedcat Part of programming is indeed problem solving. Also part of programming is using the right tools in the right situations. So many people think oh you have to be fancy can you do this without using the if statement? can you do that without using loops? That's not problem solving at all, there's never going to be a scenario where you are going to print out 1 to 100 in a console that a loop isn't going to be your best option. Those are just games and they have no real world application. What I want to know is can you use an if statement correctly, do you know when it's appropriate to use a loop and when it's not? And most importantly can you write software that works? Programming is greatly affected by opinion and you are entitled to your own but having been the lead developer on multiple projects I can tell you right now I would much rather have a developer who knew when to use a loop statement to get the job done than one who wasted my time trying to figure out a way not to use the tools supplied to them by the language.
@tushar10383 жыл бұрын
Explanation is straight forward and clear👍👍
@badlydrawnjolteon6463 жыл бұрын
in python: print(*list(range(100)), sep=' ')
@DJ-rf8kz3 жыл бұрын
nice solution, range should be 101 though. 👍🏽
@badlydrawnjolteon6463 жыл бұрын
Darian Jennings shit your right, actually it should be range(1, 101)
@DJ-rf8kz3 жыл бұрын
@@badlydrawnjolteon646 yea true to get rid of the zero too. 👌🏽
@skeppy89253 жыл бұрын
@@badlydrawnjolteon646 wouldn’t it be (1,101,1)? Last interger means it would go by increments of 1? Or is that for another function?
@badlydrawnjolteon6463 жыл бұрын
@@skeppy8925 you dont need to specify 1. range(100) = 0, 99 range(1, 100) = 1, 99 range(1, 100, 1) = 1, 99 step defaults to 1 start defaults to 0 range(start, stop, step) are the parameters
@matthiasendler72683 жыл бұрын
The IntStream also has a static rangeClosed method, where the start and the end are inclusive: IntStream.rangeClosed(1, 100).forEach(System.out::println);
@thekwoka47073 жыл бұрын
forEach() is a for loop.
@matthiasendler72683 жыл бұрын
@@thekwoka4707 well, it does not matter, because it could be well be recursion, but it is not. It's just an implementation detail of the forEach method of streams. You could use a map method, but it will always have some kind of loop construct under its belt in Java, because recursion will grow the stack as there is no tail call optimization in java... In Erlang, you would not grow the stack, as there is tail call optimization included and you have to use recursion, because there are no loop constructs available.
@dasten1233 жыл бұрын
// Without loops and without recursion: import java.util.*; public class HelloWorld { static int n = 0; public static void main(String[] args) { Timer timer = new Timer(); timer.schedule(new TimerTask() { @Override public void run() { if (n++ >= 100) timer.cancel(); else System.out.println(n); } }, 0, 1); // runs task every 1 ms } }
@miningape3 жыл бұрын
Technically Timer uses a loop so all you've really done is hidden the implementation
@simonmultiverse63493 жыл бұрын
I prefer to split the task to minimise stack usage. I use divide and conquer. define print(lo,hi) and make sure that they are integers. there are 3 cases: Case 1: if lo>hi, do nothing and return Case 2: if lo=hi, print lo and return Case 3: (now we know that lo
@PandorasFolly3 жыл бұрын
System.out.println("1 to 100 without using any loop") They never said print in an increasing fashion every number between and including 1 to 100. Also solid video my man. Good job.
@calebkirschbaum81583 жыл бұрын
The 2 ways that came to my mind was 1st, recursive as you did. But an even faster way is possible, that is only one line long. print(1 2 3 4 5 6...99 100)
@k.ravichandra10492 жыл бұрын
Thanks a Ton NAVEEN for covering this Tricky Interview Question. Great Keep up the Good work.
@rajatgarg5823 жыл бұрын
hi naveen you are doing great job by creating these kind of video... these are really helpful. thanks buddy. Really appreciate your efforts.
@Ferdam3 жыл бұрын
if forloop method isn't a loop then I could as well just write a class that does loops and call it. Recursion should be the only one accepted hehe
@yunpengling14883 жыл бұрын
Thank you very much for this video, Sir, I have a good time while learning with you. Cheers
@calebfuller47133 жыл бұрын
You can do it in one line with Julia: print(join(1:100," ")) This is probably the best way. If you want a recursive function though, the Julia version is: printrange(s,n) = begin println(s) if s
@sanketbari28263 жыл бұрын
Spilt(",") Strip()
@calebfuller47133 жыл бұрын
@@sanketbari2826 Thanks. Join() was the function I needed. Check my edited post with the new one-liner.
@sachinj78993 жыл бұрын
Thanks naveen sir. Start loving programming because of you...Keep inspiring .
@Arnankhan3 жыл бұрын
/* I have another idea. You can use an if statement and go-to statement to emulate a loop. */ #include using namespace std; int main (){ int n = 1 top: cout
@nirmanmalaviya91343 жыл бұрын
This will go into a infinite loop. You never incremented n.
@Arnankhan3 жыл бұрын
@@nirmanmalaviya9134 Updated it.
@sanketbari28263 жыл бұрын
Nice idea....But goto is deprecated
@ozrenbalic60513 жыл бұрын
I think that "printNum(num+1)" is cleaner (and more concise) than "num++; printNum(num)". Mutating num is unnecessary, we are not using new value of num after the recursive call.
@swarnasharma38363 жыл бұрын
public class PrintHundredWithoutLoop { public static void main(String[] args) { int i = 1; printNumber(i); } public static void printNumber(int n) { if(n
@shantomanob59643 жыл бұрын
Else block redundant
@joelmason68183 жыл бұрын
Do realize that this has limits. If you stack these functions to far, you'll get a stack overflow error. Here's a challenge for you. Research knights tour. Create a recursive function for path finding. You'll find this to be an extremely awesome mental exercise! 😁
@shilpabhuti16593 жыл бұрын
Hi Naveen, Thanks for the amazing content you are providing. Requesting you to make a playlist on puzzle programs. Awaiting your response.😀 Thank you ☺️
@fyzxnerd3 жыл бұрын
I've always thought of recursion as a loop. Definitely see some drawbacks though if you're not printing numbers but instead apply this as a clock. The stream/lambda function though makes sense to me.
@NomoregoodnamesD83 жыл бұрын
this function is tail-recursive which means that it doesn't do any additional work after recursing. In practice, tail-recursive functions and forloops execute at about the same speed because the function stack of a tail-recursive function can be reused.
@TheRealFigLizard3 жыл бұрын
In Python you can use map() which functions similarly to the Stream method. Something like list(map(print,list(range(1,101))))[1] should work in Python 3 if you can excuse all of the parens.
@adityaraut93643 жыл бұрын
After watching your videos, I always think why this didn't came to my mind?!?!
@samphire3 жыл бұрын
Why does everyone try to be smart and forget the simple way, cut and paste with an increment operator, the question didn't ask for reusable/alterable/compact code ;)
@ljose0073 жыл бұрын
Thanks, this was very helpful to me using C#. I used the same code with the exception of sout. I used writeline() instead. using System; using static System.Console; //using a recursive function namespace PrintNumberNoLoop { class Program { static void Main(string[] args) { PrintNumber(0,10,2);// Prints 0, 2,4,6,8 ,10 } public static void PrintNumber(int begin, int end, int increment) { if(begin
@jimmorrison26573 жыл бұрын
I don't like these sorts of questions. I think this question is just a parlor trick. To me, it doesn't really test to see if the person is a good programmer. They should be testing for cleanness and clarity of code, SOLID knowledge etc. But anyway, sometimes they do ask questions like this, so good video!
@naveenautomationlabs3 жыл бұрын
Ya Jim, just a quick Interview question. Someone asked this so thought of creating this video.
@adjmonkey3 жыл бұрын
Tbf, this type of quick thinking is definitely needed to be a good programmer. If all you can do is use a framework and cry when something doesn’t work, you’re replaceable
@jimmorrison26573 жыл бұрын
@@adjmonkey If someone can only use a framework and cries when it doesn't work, they wouldn't be a very good employee. That's true, but that wasn't in question. What I meant was that I have seen programmers who know lots of cute little tricks like this, but can't write readable, well-structured code. Personally, I would prefer the programmer who can write good code, but who doesn't know any these tricks. If they know both things, even better.
@saiadityapotham35933 жыл бұрын
Thanks bro 2nd method was new to me Java streams🙏
@anmolmalhi56703 жыл бұрын
Hello Naveen, Thanks to your wonderful videos , i got my new job in the market. what you prefer me to learn for mobile browser testing and debugging. I already worked with selenium to use mobile emulator and sauce labs and browser stack. I am not sure about the UI testing for mobile browser testing, do you have any specific video for mobile browser testing?
@CallumPooleProgrammer3 жыл бұрын
Gotta be careful of stack overflow if the range passed into the printNumber is too large
@s123123213123 жыл бұрын
U deserve a subscribe sir! Thank you so much.
@chetankat0073 жыл бұрын
Remember use recursion only when there are no IO intensive operations involved..or the system will stop responding..
@suganthiezhilmani37293 жыл бұрын
I guess we can use stream iterate method to generate values and collect them in a list to avoid using forEach method. List num = Stream.iterate(1,n-> n+1).limit(100).collect(Collectors.toList()); System.out.println(num);
@nvmcomrade3 жыл бұрын
Another way is to receive a string containing all the numbers into the main args and print it, then have a script running the program with the correct input. Also in C/C++ you can use macros and unroll a 100 statements quickly #include #define call_5(x) x; x; x; x; x; #define call_10(x) call_5(x) call_5(x) #define call_100(x) call_10( call_10(x) ) int main() { int i = 1; call_100( printf( "%d ", i ); i++; ); return 0; } In C++17 you can do this: #include template void printN_impl( std::index_sequence ) { ((std::cout
@atrumluminarium3 жыл бұрын
There's a one-liner way to do it in python using lambdas and conditional assignments if you exploit the fact that the arguments for the "or" keyword are executed in chronological order: print100 = lambda num: print(num) or print100(num+1) if num
@luketurner3143 жыл бұрын
I'll do you one better: print(*list(range(1,101)),sep=' ') unless range uses loops internally
@atrumluminarium3 жыл бұрын
@@luketurner314 I saw this variation already in another comment thread on this video it's really neat. Also you do not need the cast to list because range returns a generator and *args can unwrap generators too (which is where the loop happens under the hood but all function arguments parse using a loop so it can't really be avoided I think) So you end up with print(*range(1,101), sep=' ')
@sanketbari28263 жыл бұрын
Please make videos on dynamic programming .... tough questions....We know recursion but when it comes to dynamic programming don't know why mind just stops giving any output and goes on a different trip
@manju-ep7nj3 жыл бұрын
Sir, thank you for sharing your awesome information
@KyleHarrisonRedacted3 жыл бұрын
I mean.. this is just implementing loops yourself, the only difference is the function requires scalar values to work from instead of expressions And the following streams example uses a functional loop with. ForEach These kinds of interview questions make me nervous because they're often asking you to do the worst, least efficient, and most terribly annoying way to solve a programming problem with pants-on-head style unrealistic restrictions Like kids asking "who'd win? Batman but he's in a wheel chair and missing his left arm and right leg, OR superman but he's just eaten kryptonite cereal for breakfast that day and broke every one of fingers as well he's just heard the news that his dog just died"
@mohamedsulaimaansheriff97873 жыл бұрын
Recursion🔥🔥🔥
@dmatscheko3 жыл бұрын
System.out.println("1 to 100 Without Using Any Loop in Code using recursive function and java streams."); There.. prints exactly what was asked ;)
@Howltusk3 жыл бұрын
would i still get it right if i just typed each number manually 🧐
@RSTPhysics3 жыл бұрын
Can also call recursive function first and print afterwards and decrease num for each instead and check if less than 1 as a exit statement, that way you can specify maximum number as a input right away. Sorry for python ;) def printnum(num): if num > 0: printnum(num-1) print(num) printnum(100)
@phlox223 жыл бұрын
Damn how can I forget Recursive method 😭
@GemaPratamaAditya3 жыл бұрын
my very stupid way to answer this question: System.out.println("1"); System.out.println("2"); System.out.println("3"); System.out.println("4"); ... System.out.println("100"); there. no loops.
@naveenautomationlabs3 жыл бұрын
Now print 1 to 10000. ;)
@shaikhshahbaz70133 жыл бұрын
@@naveenautomationlabs 😂😂😂
@debashishrath95413 жыл бұрын
If 1 to 1000 needs to be printed and in this way it's done, then situation be like: Khataaam...tata...bye bye....😆😆😆😆🤣🤣🤣
@gregorymorse84233 жыл бұрын
@@naveenautomationlabs try printing 1 to 100000 with recursion and overflow the stack. The recursion method is even worse. Better would be to use C style macros to expand the code out 1 to n times
@AssassinGamer3 жыл бұрын
@@naveenautomationlabs for (int i = 0; i
@ranselynigrel87142 жыл бұрын
Getting StackOverflow Error with this solution .... however numbers are getting printed
@bardplaygames3 жыл бұрын
my first instinct was a bit caveman: print("1") print("2") print("3") print("4") . . . print("100")
@khodis20023 жыл бұрын
I see a python-semihuman here
@kophaziistvan64773 жыл бұрын
Okay, the recursive one is a correct solution, although I don't like it because it will not work for larger numbers. Isn't forEach in stream API considered a for loop? Then let me paste my solution: System.out.println("1"); System.out.println("2"); System.out.println("3"); System.out.println("4"); System.out.println("5"); System.out.println("6"); System.out.println("7"); System.out.println("8"); System.out.println("9"); System.out.println("10"); System.out.println("11"); System.out.println("12"); System.out.println("13"); System.out.println("14"); System.out.println("15"); System.out.println("16"); System.out.println("17"); System.out.println("18"); System.out.println("19"); System.out.println("20"); System.out.println("21"); System.out.println("22"); System.out.println("23"); System.out.println("24"); System.out.println("25"); System.out.println("26"); System.out.println("27"); System.out.println("28"); System.out.println("29"); System.out.println("30"); System.out.println("31"); System.out.println("32"); System.out.println("33"); System.out.println("34"); System.out.println("35"); System.out.println("36"); System.out.println("37"); System.out.println("38"); System.out.println("39"); System.out.println("40"); System.out.println("41"); System.out.println("42"); System.out.println("43"); System.out.println("44"); System.out.println("45"); System.out.println("46"); System.out.println("47"); System.out.println("48"); System.out.println("49"); System.out.println("50"); System.out.println("51"); System.out.println("52"); System.out.println("53"); System.out.println("54"); System.out.println("55"); System.out.println("56"); System.out.println("57"); System.out.println("58"); System.out.println("59"); System.out.println("60"); System.out.println("61"); System.out.println("62"); System.out.println("63"); System.out.println("64"); System.out.println("65"); System.out.println("66"); System.out.println("67"); System.out.println("68"); System.out.println("69"); System.out.println("70"); System.out.println("71"); System.out.println("72"); System.out.println("73"); System.out.println("74"); System.out.println("75"); System.out.println("76"); System.out.println("77"); System.out.println("78"); System.out.println("79"); System.out.println("80"); System.out.println("81"); System.out.println("82"); System.out.println("83"); System.out.println("84"); System.out.println("85"); System.out.println("86"); System.out.println("87"); System.out.println("88"); System.out.println("89"); System.out.println("90"); System.out.println("91"); System.out.println("92"); System.out.println("93"); System.out.println("94"); System.out.println("95"); System.out.println("96"); System.out.println("97"); System.out.println("98"); System.out.println("99"); System.out.println("100");
@TravelMania20223 жыл бұрын
Keep making more interesting videos on coding
@intrestingfacts67853 жыл бұрын
Please make videos on data structures and algorithms
@charbelfayad5063 жыл бұрын
Your taskbar looks scary :)
@alpanakarmarkar28673 жыл бұрын
Thumbnail is scarier
@subbaraogannavarapu74053 жыл бұрын
Commenting without starting video. We can use streams to solve this problem. Awesome work Naveen🙏
@nikhilraosanas24633 жыл бұрын
If i talk about C lang then we can use goto statement to print 1 to n numbers without any loop or any function which is using loop internally
@gregorymorse84233 жыл бұрын
Goto creates a loop if it jumps backwards. Though not a for or while one.
@yevheniibatiievskyi3 жыл бұрын
IntStream.range(startNumber, endNumber + 1).forEach(System.out::println); instead of Lambda
@immortalhuman70853 жыл бұрын
After using recursion for factorial , I now using for this 😂😂
@ajay2302ful3 жыл бұрын
Ha ha...same thought came to me😀
@Evolutionmine163 жыл бұрын
You could also just write 100 System.out.println() calls and hardcode in the numbers. Probably the most efficient algorithm lol
@simonmultiverse63493 жыл бұрын
...but then you would need to write a program to write the text of the 100 System.out.println() calls. That means you'd be writing a program which wrote a program. Cooooooooool!
@GeorgeSukFuk3 жыл бұрын
@@simonmultiverse6349 were already in a simulation so you're already a program writing a program
@simonmultiverse63493 жыл бұрын
@@GeorgeSukFuk If you wanted another name, you could always choose "Lickadick."
@GeorgeSukFuk3 жыл бұрын
@@simonmultiverse6349 my name is a play on the name of George stephanopoulos so that might not work as well, but thanks for the idea!
@BayernTime3 жыл бұрын
Could you also use a dynamic switch statement? Like a variable that increments and a case statement that also increments? I don’t know if switch statements are allowed to have dynamic cases?
@thenewone48123 жыл бұрын
Should I learn Java?or python is enough?
@arthurg59663 жыл бұрын
1. Print string(code) using for loop, System.out.println("1"); System.out.println("2"); ... System.out.println("n"); 2. Copy and paste this code(strings) in your code and run
@balachandar62063 жыл бұрын
😂
@vipul11923 жыл бұрын
I see this I get thought of recursion
@gnsc2 жыл бұрын
You're awesome bro.
@suprabathj78433 жыл бұрын
Thank you, great content
@vinayakbhandage83193 жыл бұрын
Can u make a video on java streams completely.
@sainiranjan403 жыл бұрын
Thank you Naveen :)
@biolinseeds35353 жыл бұрын
Foreach uses a loop internally. It's just syntactic sugar.
@deecee22043 жыл бұрын
i have 2 ways 1, recursion 2, goto (old programs) 😁
@loknathshankar54233 жыл бұрын
How does the traceback work in java, shouldn't it unwind back to initial value?
@adjmonkey3 жыл бұрын
No, because he prints before the recursive step. If he was to do something like println(return(printNum(++n))); then it would start at the at the top and come back down
@mayanknegi24713 жыл бұрын
Does these type of questions are really asked in interview? These looks trivial and no real use
@naveenautomationlabs3 жыл бұрын
Ya why not? It's a basic example of recursion. Not every question has a real use case.
@maheshbabu99093 жыл бұрын
I faced yesterday only 😁
@kennymccormic75783 жыл бұрын
System.out.println(1); System.out.println(2); .... System.out.println(100); Generate it using vim macro.
@KP-ih1hm3 жыл бұрын
Thank you Naveen
@suhasdoke11573 жыл бұрын
What is the use of this? If you use recursion , ultimately you are doing the loop. Because at machine level you are just using the goto operand. In fact recursion will be inefficient as it has to push all the 99 calls on stack and them pop them back and process
My solution would be hardcoding since that's the only method that truly does not use loops Also recursion without the if loop inside of it - but recursion is looping so i'd call it a half-solution. There is no declared loop but the program loops itself.
@vamsikrishna23293 жыл бұрын
Don't you think for each is still a loop?
@khodis20023 жыл бұрын
Is this ment to he hard? It doesn't seem like that
@Aks-gj1kp3 жыл бұрын
How is foreaach not a loop, not directly but its still kind of a loop.
@bin_underscore3 жыл бұрын
Thank you Naveen.
@balachandar62063 жыл бұрын
Recursion type creating stack over flow error Bro.....how to encounter it pls..😭
@naveenautomationlabs3 жыл бұрын
You need to break the condition in your logic to come out of recursion.
@Omikoshi783 жыл бұрын
Can’t use “for loop” proceeds to use foreach. Next challenge, avoid using rcx register.
@satyamkaushik44673 жыл бұрын
Thank you sir !!
@gorilladisco91083 жыл бұрын
eh .. what about "it's work so it's not stupid" method? the one that print it right away?