Commit Graph

121 Commits

Author SHA1 Message Date
Geoff Liu
6eeb1f962e Merge pull request #1872 from luehm/c_cases
[C/en] Added tidbit about fall-though in switch statements.
2015-12-18 17:22:50 -05:00
Alex Luehm
3b1940b9cc [C/en] Added tidbit about fall-though in switch statements.
Another pitfall, as not all languages have fall-through in switches.
2015-10-28 17:45:31 -05:00
Jody Leonard
b31fda3a8e Edit variable-length array example
The current example seems to be trying to set a size for a char buffer,
use fgets to populate that buffer, and then use strtoul to convert the
char content to an unsigned integer. However, this doesn't work as
intended (in fact, it results in printing "sizeof array = 0"), and so
adapt to a simpler fscanf example. Also remove some ambiguous language
in the example output.
2015-10-26 19:38:36 -04:00
Brendan Batliner
36fe7e1cce Added example of printIntArray in C 2015-10-15 16:38:42 -05:00
Brendan Batliner
2acf7822bd Update c.html.markdown
Added additional info on dynamically allocated arrays in C.
2015-10-15 16:34:53 -05:00
Zachary Ferguson
8417366a1b Cleaned up c file 2015-10-15 14:50:20 -04:00
Zachary Ferguson
65bb71f4bd Merge remote-tracking branch 'refs/remotes/adambard/master'
Conflicts:
	c.html.markdown
2015-10-15 14:48:59 -04:00
Levi Bostian
063c962254 Merge pull request #1512 from awalGarg/patch-2
[c/en] clarify common tripping point of newbies
2015-10-15 13:01:15 -05:00
Levi Bostian
c1982009c7 Merge pull request #1511 from awalGarg/patch-1
[c/en] clarify that args' names are not required in proto
2015-10-15 13:00:53 -05:00
ven
adc81a0bc5 Merge pull request #1480 from eltonvs/master
Translation fixes and extra information
2015-10-15 09:09:40 +02:00
Zachary Ferguson
27bb1a1e80 Removed separate code section
Removed the separate code section for header files
2015-10-14 21:59:42 -04:00
Elton Viana
328ceb1a94 Some extra information 2015-10-14 21:44:42 -03:00
Awal Garg
4599cd319f [c/en] clarify common tripping point of newbies
int foo () {
  printf("bar\n");
  int x; // this is not valid in C89+
}
2015-10-14 20:44:45 +05:30
Awal Garg
223c8140a0 clarify that args' names are not required in proto
with obligatory conventional warning
2015-10-14 20:41:36 +05:30
Zachary Ferguson
79ced08e09 Added Header title
+ Added a header file title
* Changed ```c to ```h
2015-10-13 11:05:20 -04:00
Levi Bostian
841f4c3d46 Merge pull request #1399 from himanshu81494/master
example function added for call by reference
2015-10-12 23:14:27 -05:00
Zachary Ferguson
e418849d76 [c/en] Added a section for header files.
Added a section for header files.
Included a discussion of what belongs in a header file and what does
not.
2015-10-09 11:52:08 -04:00
himanshu81494
c899b6605e Update c.html.markdown 2015-10-09 20:59:05 +05:30
Andy B
e8e8b9c76f [C/en] Accessing command line arguments in main 2015-10-09 15:48:21 +01:00
himanshu81494
e8248af134 Update c.html.markdown 2015-10-08 15:31:40 +05:30
himanshu81494
626ee03fc3 Update c.html.markdown 2015-10-08 14:45:16 +05:30
himanshu81494
9796759379 Update c.html.markdown 2015-10-08 14:44:10 +05:30
Zachary Ferguson
3c02fdb8e4 Revert "[c/en] Added a section for header files."
This reverts commit e1ac6209a8.
2015-10-07 23:49:46 -04:00
Zachary Ferguson
e1ac6209a8 [c/en] Added a section for header files.
Added a section for header files.
Included a discussion of what belongs in a header file and what does
not.
2015-10-07 23:45:01 -04:00
Pushkar Sharma
2e987df422 replaced scanf with fscanf. 2015-10-05 00:52:47 +05:30
Pushkar Sharma
c7e552c448 Variable size array, user size input added. #1170
Fixed Issue #1170
Variable size array, user size input added.
2015-10-04 10:34:31 +05:30
Joe Savage
e0d0e9189b revert additional resource suggestion in c.html.markdown 2015-08-30 20:51:58 +01:00
Joe Savage
7cb94b3b85 main() -> main(void) & fix spacing in c.html.markdown 2015-08-29 11:58:03 +01:00
Joe Savage
85d80b9e5d fix resource capitalisation and add resource to c.html.markdown 2015-08-29 11:47:09 +01:00
Joe Savage
3d0687027a add missing semicolons in c.html.markdown 2015-08-29 11:44:41 +01:00
Max Filippov
e267eed62c c.html: fix #1021 (bitwise negation and shifting into the sign bit)
0x0f is of type int, for 32-bit int the result is 0xfffffff0.
31'st bit is the sign bit of a 32-bit wide int.
2015-03-30 10:11:05 +03:00
Devin McGinty
21fa7d7e39 Change explanation of unsigned types 2015-01-30 16:42:35 -05:00
mordner
d1171443dd Fixed one line being cut off and a comment about the export attribute
was referring to the wrong function and variable.
2015-01-08 23:24:19 +01:00
Ruben
8291fb2d7d Update c.html.markdown 2014-12-08 13:27:06 +01:00
Martin Thoresen
d179669f39 fix #873 2014-11-24 17:37:55 +01:00
Wes Turner
56d86a244e [c/en] Typo: integral -> integer 2014-11-02 04:52:31 -06:00
Levi Bostian
0ec14c6914 Add fixes from @marcom's PR https://github.com/adambard/learnxinyminutes-docs/pull/765 2014-10-17 20:57:18 -05:00
adventuretc
a5b7319eac Correction to use the intended variables. 2014-09-27 21:38:30 +02:00
Levi Bostian
cd7ed4f9f9 Couple changes to C to close https://github.com/adambard/learnxinyminutes-docs/pull/594 2014-09-05 20:47:18 -05:00
Ben Eysenbach
c0c77e850c Clarified C Octal Character
This fixes issue #658
2014-09-03 22:46:50 -04:00
iirelu
a9f51d5bbf Made learnc's switch statement clearer
Also cleaned up trailing whitespace.
2014-07-17 20:37:52 +01:00
iirelu
50fe4d9859 Commented out two broken lines in learnc.c 2014-07-17 17:08:30 +01:00
Nami-Doc
15353d1938 Fix c tutorial
Fixes #678

Still missing symbols, though
2014-07-17 10:46:24 +02:00
Nick Ward
104b9add58 Fix spelling and other small issues 2014-06-28 12:58:50 +10:00
Nattaphoom Ch
e8910da685 Added missing semicolons and correct some words. 2014-05-28 01:10:46 +07:00
Jakukyo Friel
2a9fb70f6d c: typo 2014-02-14 20:34:23 +08:00
Jakukyo Friel
4c25ac36c6 c: reorder paragraphs
content about `static` are inserted into the wrong place.
2014-02-14 17:22:38 +08:00
Joseph Adams
c9a32b08e7 Added missing comma in printf 2014-01-10 18:28:34 +01:00
Joseph Adams
c8b12bd824 Added verb ("is") where it was missing 2014-01-10 18:14:35 +01:00
Levi Bostian
af6701904b Fix conflict bash. 2013-11-25 09:42:37 -06:00