Parse CSV file in C [closed] - c

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 4 years ago.
Improve this question
Is there a library I can use to parse CSV files in C. I am on a Linux system. I know about this but it is in C++ and I need something in C. Don't want to go through the pain of debugging and testing if someone has already done it.

Take a look at libcsv, which is a CSV library written in ANSI C89.

There's a simple CSV parser library that's described in the excellent book The Practice of Programming by
Kernighan and Pike, and the source is available from the site linked to.

Parsing a CSV is no too much complicated, depend of the CSV structure, take a look at the strtok function.

Related

Clean up a csv file in C [duplicate]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 4 years ago.
Improve this question
Is there a library I can use to parse CSV files in C. I am on a Linux system. I know about this but it is in C++ and I need something in C. Don't want to go through the pain of debugging and testing if someone has already done it.
Take a look at libcsv, which is a CSV library written in ANSI C89.
There's a simple CSV parser library that's described in the excellent book The Practice of Programming by
Kernighan and Pike, and the source is available from the site linked to.
Parsing a CSV is no too much complicated, depend of the CSV structure, take a look at the strtok function.

Does anyone know an API for decoding strings like cron does in C? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
I'm a newbie in C and i want to read a file which lines are like 30 7 * * 14-15 and parse to date structures.
So i would really use your help to find an API or an algorithm to do it.
Try to read sources, for example concerning freebsd, fetch os sources (if not aredy done as part of standart os upgrade procedure) , find cron, see sources, take what you need. It is not so unreal as seems.
Sources well documented at comments:
https://svnweb.freebsd.org/base/stable/9/usr.sbin/cron/cron/database.c?revision=225736&view=markup
UPD: link suggested in comment by #PeterT (more exactly for parsing entry):
https://svnweb.freebsd.org/base/stable/9/usr.sbin/cron/lib/entry.c?view=markup#l88

Is there any tool to convert C to J2ME? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 3 years ago.
Improve this question
Is there any tool to convert C to J2ME? Help me by providing their list and Links.
There are alternatives for using other programming language to program for Java ME. There are compilers and interpreters.
This answers the question,Cibyl is a programming environment and binary translator that allows compiled C programs to execute on Java ME and BlackBerry phones
MidletPascal - Compiles Pascal to Java ME midlet
There's another interesting tool . Alchemy-OS, it is an environment inside an environment which is Java ME,which interprets the Ether(was E) programming language
Surely not.
J2ME requires certain methods to implemented.
Why should any C code takes this into account?

Parsing JSON using C? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
There are several C libraries available for parsing JSON, that will compile on Linux. Which library would you recommend?
Just to close the loop:
For the project in question, we ended up going with cJSON. We chose this one from the list of C libraries linked from json.org. Per the homepage, cJSON is:
An ultra-lightweight, portable, single-file, simple-as-can-be ANSI-C compliant JSON parser, under MIT license.
This happened to be a good fit for the particular project at hand, and the library worked out fine.
I've seen YAJL used with MGTwitterEngine (Mac/Cocoa), so I assume it is ok.
I haven't done much with it apart from compiling it and pointing MGTwitterEngine on Mac to its library/header files.
Check out the list at json.org. There are several C libraries for JSON.

Best stats library for C (not C++) [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
Anyone know of a good statistics library for C? I'm looking for something that is commonly used and not a small project. EDIT: must be free!
gsl (http://www.gnu.org/software/gsl/) is widely available, portable, and has a lot of nice functionality.
Statistics are frequently done in other languages, but some of those languages will be callable from C. I'd recommend looking at R and Octave; the latter is an open source Matlab work-alike. Both are programming languages in their own right, but many other languages can be called from C.
In my opinion, MATLAB is a very good choice you can use for that. Here is an article on how to call MATLAB from C.
It ain't cheap. But you did not specify anything about the library being cheap or free. Plus, you are mentioning it's a big project.... :-)

Resources