Welcome, Guest: Register On Nairaland / LOGIN! / Trending / Recent / NewStats: 3,153,845 members, 7,820,942 topics. Date: Wednesday, 08 May 2024 at 04:18 AM |
Nairaland Forum / Science/Technology / Programming / Lets Learn C (9239 Views)
Is It Possible To Learn C++ In A Year? / Learn C++ Programming Language In Few Days / Lets Learn Programming From Bignners To Expert Through Tutorials (2) (3) (4)
(1) (2) (3) (4) (5) (Reply) (Go Down)
Re: Lets Learn C by romme2u: 2:43am On Jul 26, 2016 |
stack1: that is cool |
Re: Lets Learn C by stack1(m): 2:43am On Jul 26, 2016 |
lets see another basic for loop usage... |
Re: Lets Learn C by stack1(m): 2:53am On Jul 26, 2016 |
This code is similar to the last except the updateStament counts downwards
Here is the output: Count down started 5 ! 4 ! 3 ! 2 ! 1 ! We have ignition! the statement secs-- is a post-decrement (as opposed to increment) and it decreases the value of variable sec by one after each execution of the loop body |
Re: Lets Learn C by stack1(m): 2:56am On Jul 26, 2016 |
... a few more for loop examples |
Re: Lets Learn C by stack1(m): 3:04am On Jul 26, 2016 |
By the way my good people them, when learning any form of programming, don't rely only on the source you are learning form, learn to digg deeper on your own (Google is your friend here), how fast and well you'll learn truly depends on how enthusiastic u are and how far you are willing to research further on your own |
Re: Lets Learn C by Nobody: 6:25am On Jul 26, 2016 |
@op, keep up the good work, am using this to refreshy my rusty memory. |
Re: Lets Learn C by bestiyke(m): 6:32am On Jul 26, 2016 |
stack1:I don't know what you mean. My heart is as clear as crystal. I'm only delighted by your tutorial posts. I don't know when *'dear' became gender sensitive. We Nigerians and our myopic reasoning. Sorry anyway if it is a wrong word. |
Re: Lets Learn C by Nobody: 7:35am On Jul 26, 2016 |
bestiyke:Oh, you are not even a Nigerian, no wonder. If a man calls me DEAR in the real world, I would have done a 70-moves-kata on his head before he explains himself. |
Re: Lets Learn C by stack1(m): 7:51am On Jul 26, 2016 |
dhtml18: LOL, i thought i was only joking anyway.. |
Re: Lets Learn C by stack1(m): 7:53am On Jul 26, 2016 |
bestiyke:Myopic?, bro, me just dey catch fun nah. shu, but then again its not a standard way guys address each other for our 9ja |
Re: Lets Learn C by stack1(m): 7:55am On Jul 26, 2016 |
I might or might not be posting much for the next few days, as i got some waka waka to do, please if anyone has got questions up to this point?? |
Re: Lets Learn C by bestiyke(m): 9:20am On Jul 26, 2016 |
stack1:Apology!!! Some how I was disappointed because the comment was beyond my imagination. |
Re: Lets Learn C by bestiyke(m): 9:25am On Jul 26, 2016 |
dhtml18:I don't have a word for u because everyone on Nairaland/programming session knows your character. I still respect you person anyway. |
Re: Lets Learn C by furthest(m): 9:38am On Jul 26, 2016 |
please every1 I need a complier..I can't find any online..please help a bro here |
Re: Lets Learn C by stack1(m): 9:44am On Jul 26, 2016 |
bestiyke: guys can we end this matter |
Re: Lets Learn C by stack1(m): 9:48am On Jul 26, 2016 |
furthest: bro i pasted the links for both 32bit and 64bit GCC compilers on page 1 and inatructions on setting them upe with code blocks, aanyway here are the links again if you are on 32bit windows get this file here https://sourceforge.net/projects/mingw-w64/files/Toolchains%20targetting%20Win32/Personal%20Builds/dongsheng-daily/6.x/gcc-6-win32_6.1.1-20160715.7z/download and for 64bit systems get this https://sourceforge.net/projects/mingw-w64/files/Toolchains%20targetting%20Win64/Personal%20Builds/dongsheng-daily/6.x/gcc-6-win64_6.1.1-20160715.7z/download |
Re: Lets Learn C by furthest(m): 9:50am On Jul 26, 2016 |
stack1:thanks bro |
Re: Lets Learn C by furthest(m): 1:27pm On Jul 26, 2016 |
furthest:bro i cant find it. i installed it in c directory |
Re: Lets Learn C by furthest(m): 1:42pm On Jul 26, 2016 |
please how do i compile? |
Re: Lets Learn C by stack1(m): 2:21pm On Jul 26, 2016 |
the GCC compiler package in the link i pasted would download as a 7z archive so you'll need a tool such as WinRar (http://www.rarlab.com/download.htm) or 7-zip (http://www.7-zip.org/download.html) to extract the contents, after extracting ( i only recommend extracting to the root of your C: drive, any other location should do) you then setup Codeblocks to use the GCC compilers from the Settings->Compilers menu Then you can directly compile from the build menu |
Re: Lets Learn C by 2mNaira: 10:11pm On Jul 28, 2016 |
stack1: I wanted to ignore this thread altigether,but decided against it.Why dont u intrioduce operators(like addition etc) and control statements (while,for goto and return ) to us first. If pple are already graspg it as it is then no problem. |
Re: Lets Learn C by Nobody: 10:28pm On Jul 28, 2016 |
is alright, join the fun |
Re: Lets Learn C by stack1(m): 11:13pm On Jul 28, 2016 |
mnairaland: am already doind that bro, see the last few post's, yeah i know i shoulld have started with d basics,make una no vex, currently on for loops, and sorry to everyone for not posting anything on-topic for a feew dayz now bn away from my system and i no fit type long post on phone, would continue tommorow (if Nepa coporates that is) |
Re: Lets Learn C by 2mNaira: 1:59am On Jul 29, 2016 |
dhtml18: I suspect that this comment is directed at me.If it is,I'd say that I made that comment just to steer him in d right direction.have been programmg in C/C++ for about a decade. I did not want to sound like an intimidating Guru.Although its a good job he is doing here, I still have ignore the thread.Its not for me. |
Re: Lets Learn C by Nobody: 7:00am On Jul 29, 2016 |
^^^it matters not whether you are a guru or not, just have fun and enjoy the thread, that is why i am here to, to encourage the OP. |
Re: Lets Learn C by stack1(m): 9:33am On Jul 29, 2016 |
dhtml18: dhtml18 |
Re: Lets Learn C by Nobody: 11:07am On Jul 29, 2016 |
stack1:dont mind that boy, he is an E-TROLL. |
Re: Lets Learn C by stack1(m): 8:25am On Jul 30, 2016 |
The update statement in for loops do not need to be increased/decreased by one, any arbitrary number or expression would do
This would increase n by 13 during each cycle, printing the following: 2 15 28 41 54 In the above program, the variable n is initialized with the value 2, and then the loop checks runs only if the value of variable n is less than 60, and then after each run of the loop n is increased by 13, this process continues till the test condition n < 60 fails and the loop is then terminated |
Re: Lets Learn C by stack1(m): 8:34am On Jul 30, 2016 |
Here we show that more complex expressions can be used for any of the values in a for loop
This loop prints the values of x and of the algebraic expression ++x * 5 + 50 . The output looks like this: 1 55 2 60 3 65 4 70 5 75 While we haven't discussed operator in-depth the expression (++x * 5) + 50 should be trivial to comprehend The variable (x) is first initialized to 1 in the loop's initialization statement. Then in the update statement it is per-incremented by one then multiplied by five, and the result added to 50 |
Re: Lets Learn C by stack1(m): 8:40am On Jul 30, 2016 |
In the last example you'll notice the for loop's body isn't enclosed in braces {} generally if the body of a loop is contained wholly one one line the braces can be excluded |
Re: Lets Learn C by stack1(m): 8:42am On Jul 30, 2016 |
[size=16pt]while[/size] loops |
Re: Lets Learn C by stack1(m): 8:51am On Jul 30, 2016 |
The while loop is another general purpose loop, and is renowned for its compactness and ease in handling complex loop expressions the basic form of the while loop is
The control-expression or statement parts could be simple or complex statements The basic operation of the while is straight forward -- the loops control-expression is evaluated first and if the result of the evaluation is non-zero/non-false the statement contained in the loop's body is executed, this process is repeated until the control-expression fails |
How Do You Get A CEH / Pentesting Job In Nigeria? / Android Quiz Application With Json Parser, Php And Mysql Database / C++ Or Java: Which Way To Go?
(Go Up)
Sections: politics (1) business autos (1) jobs (1) career education (1) romance computers phones travel sports fashion health religion celebs tv-movies music-radio literature webmasters programming techmarket Links: (1) (2) (3) (4) (5) (6) (7) (8) (9) (10) Nairaland - Copyright © 2005 - 2024 Oluwaseun Osewa. All rights reserved. See How To Advertise. 41 |