Search Results

Showing results 1 to 40 of 618
Search took 0.08 seconds.
Search: Posts Made By: ~s.o.s~ ; Forum: C and child forums
Forum: C May 8th, 2009
Replies: 33
Views: 70,556
Posted By ~s.o.s~
I'm pretty sure there isn't much of value which could to added to this thread. Locking it to prevent more shaman interference seems like a sane decision.

For those who have come to this thread via...
Forum: C Jan 25th, 2009
Replies: 2
Views: 3,246
Posted By ~s.o.s~
In Javascript:var input = "03857";
var arr = ["zero", "one", "two", "three", "four", "five", "six", "seven", "eight", "nine"];
var output = input.replace(/(.)/g, function(a, b) {
var i =...
Forum: C Nov 15th, 2008
Replies: 3
Views: 693
Posted By ~s.o.s~
Congratulations on using:
- Code tags for your first post.
- int main(void) instead of the usual void main() for your first post.
You have a bright future ahead! :-)

Anyways, your problem is a...
Forum: C Aug 27th, 2008
Replies: 42
Read Me: Starting " C "
Views: 52,804
Posted By ~s.o.s~
A few useful links:
• Avoiding memory leaks (http://developer.gnome.org/doc/guides/programming-guidelines/memory-leak.html)
• Yet another C Reference...
Forum: C Nov 24th, 2007
Replies: 58
Views: 4,973
Posted By ~s.o.s~
r5ing:

A few things:
» Don't use scanf or it's non-standard variants for accepting user input. There are better ways of achieving it. Read this...
Forum: C Jul 18th, 2007
Replies: 4
Views: 2,777
Posted By ~s.o.s~
Try something like this. It would work for any kind of whitespaces (newline, spaces, tabs).


int main(void)
{
char str[] = " hello \n to all \n\r\f the \t people ";
int limit =...
Forum: C Jul 15th, 2007
Replies: 6
Solved: C with XML
Views: 970
Posted By ~s.o.s~
Though I personally haven't used it, this (http://expat.sourceforge.net/) seems promising.
Forum: C Jul 8th, 2007
Replies: 4
Views: 2,110
Posted By ~s.o.s~
Read this. (http://www.cppreference.com/escape_sequences.html)
Forum: C Jul 8th, 2007
Replies: 21
Views: 3,824
Posted By ~s.o.s~
Not necessarily, it was a trick question. See this. (http://www.daniweb.com/forums/post109197-4.html)
Forum: C Jul 6th, 2007
Replies: 11
Views: 2,021
Posted By ~s.o.s~
Ram, please create your own thread for your question. Hijacking other peoples' thread is against the forum rules.
Forum: C Jul 6th, 2007
Replies: 12
Crc
Views: 1,997
Posted By ~s.o.s~
> Do you look like your avatar?.
He meant gender. And yes, I do look like my avatar. :-)
Forum: C Jul 3rd, 2007
Replies: 9
Solved: Help needed
Views: 1,634
Posted By ~s.o.s~
I only noticed that you have just started out with programming. Read good tutorials, practice a lot and come back when you have got specific queries. :-)
Forum: C Jun 30th, 2007
Replies: 9
Solved: Help needed
Views: 1,634
Posted By ~s.o.s~
Bobs, I would still recommend you to read some good tutorials on C or get some good C books from a store near you to do some reading. Without putting effort or learning on your part, explaining what...
Forum: C Jun 30th, 2007
Replies: 5
Views: 1,680
Posted By ~s.o.s~
Praneeth you should use code tags for posting your code. This is the third time I have edited your post to add code tags. Take some time to read the forum announcements and the stickies at the top of...
Forum: C Jun 29th, 2007
Replies: 6
Views: 7,330
Posted By ~s.o.s~
> I am very confused. How in the world are you going to implement a stack using function pointers?
I guess he means by using dynamic memory allocation, using a node structure which holds the data...
Forum: C Jun 28th, 2007
Replies: 9
Solved: Help needed
Views: 1,634
Posted By ~s.o.s~
Looking at your code, I can clearly see that you are desperately struggling with the language. Maybe you should try to get a firm grip over the langauge(or computer science concepts) rather than...
Forum: C Jun 26th, 2007
Replies: 20
Views: 5,196
Posted By ~s.o.s~
Doesn't this sum up to...
Forum: C Jun 25th, 2007
Replies: 20
Views: 5,196
Posted By ~s.o.s~
> However I thought that behavior underfined ment that the compiler
> doesn't know what to do, therefore it would not compile.
You are getting confused between the two of them. Using clrscr() is...
Forum: C Jun 24th, 2007
Replies: 20
Views: 5,196
Posted By ~s.o.s~
> Making your code not portable.
AFAIK, the code is portable, the behavior is undefined. Though it might work for you on each run, the same can't be said about it on another machine, compiler or...
Forum: C Jun 24th, 2007
Replies: 20
Views: 5,196
Posted By ~s.o.s~
Read for gets() (http://www.gidnetwork.com/b-56.html) and fflush(stdin) (http://www.gidnetwork.com/b-57.html).
Forum: C Jun 24th, 2007
Replies: 20
Views: 5,196
Posted By ~s.o.s~
It doesn't return anything, the comparison just uses the value of *s to control the loop. The moment it equals to '\0' i.e. the moment the null terminator character is copied from the destination...
Forum: C Jun 22nd, 2007
Replies: 6
Views: 958
Posted By ~s.o.s~
Its always a good practice not to ignore warnings which appear when you compile your code. A warning about 'converting from float to int' would have given you the reason why your program is not...
Forum: C Jun 22nd, 2007
Replies: 18
Views: 56,683
Posted By ~s.o.s~
No, this is no bug. Considering that the thread was started way back in 2004 and this is the most common warning message one encounters when using a gcc or g++ compiler, coupled with the fact that...
Forum: C Jun 20th, 2007
Replies: 8
Views: 1,292
Posted By ~s.o.s~
> one of them said that C uses 2 bytes in windows for int
Someone trying out a sizeof(int) on a prehistoric compiler would definitely say that.
Forum: C Jun 14th, 2007
Replies: 1
Views: 2,497
Posted By ~s.o.s~
AFAIK, no, there is no certification in C.
Forum: C Jun 12th, 2007
Replies: 23
Views: 13,970
Posted By ~s.o.s~
No need of another buffer, a simple swap should do the trick.


int i, j;
char ch;
for(i = 0, j = nblocks - 1; i <= j; ++i, --j)
{
ch = iobuf[i];
iobuf[i] =...
Forum: C Jun 11th, 2007
Replies: 23
Views: 13,970
Posted By ~s.o.s~
#include <stdio.h>
#include <stdlib.h>

int main(int argc, char *argv[])
{
size_t filesize;
size_t nblocks = 1;
FILE *in, *out;

/* check no. of arguments */
Forum: C Jun 11th, 2007
Replies: 23
Views: 13,970
Posted By ~s.o.s~
You are using the fread function incorrectly by swapping the position of the second and third parameter. The second parameter is not the size of the entire file, but the size of each chunk.

Try...
Forum: C Jun 4th, 2007
Replies: 4
Views: 5,435
Posted By ~s.o.s~
Write your own function which has the same functionality as that of putpixel. If you have no idea how to go about it, maybe it is too difficult a task for you to undertake, not to mention you would...
Forum: C Jun 3rd, 2007
Replies: 27
Views: 4,663
Posted By ~s.o.s~
I guess this is what Narue gets for letting budding programmers close to her. ;-)
Forum: C May 27th, 2007
Replies: 6
Views: 1,040
Posted By ~s.o.s~
And jlb please stop posting in bold. Its not that your post would assume utmost importance if you do so.
Forum: C May 27th, 2007
Replies: 4
Views: 6,115
Posted By ~s.o.s~
> How to you handle tabs?
If you will notice, this is not a generic function, the way we have in Python, Ruby and other languages. You need to pass the character to be stripped. If you want to strip...
Forum: C May 25th, 2007
Replies: 3
Views: 1,138
Posted By ~s.o.s~
union in C/C++ is basically a mechanism to store more than one of variable at a given memory location. It has a variety of uses. Look here (http://www.mycplus.com/cplus.asp?CID=7) and here...
Forum: C May 23rd, 2007
Replies: 5
Views: 1,088
Posted By ~s.o.s~
Library calls execute within the process space of the `C or C++ runtime' whereas System calls spawn a separate process and the control is transferred from the current process to the newly spawned...
Forum: C May 21st, 2007
Replies: 5
Views: 13,000
Posted By ~s.o.s~
http://www.daniweb.com/techtalkforums/thread59789.html
Forum: C May 20th, 2007
Replies: 4
Views: 1,449
Posted By ~s.o.s~
Also don't cross post. Your question has been already answered in the Java forum.
Forum: C May 19th, 2007
Replies: 13
Views: 3,367
Posted By ~s.o.s~
And just a passing thought, I would stay away from using 'string' as a variable name. Converting that program from C to C++ would be a maintenance headache.
Forum: C May 19th, 2007
Replies: 13
Views: 3,367
Posted By ~s.o.s~
Aia, the above solution is overly complicated, not to mention doesn't work. Its always recommended to initialize the char array to '\0' and not to use gets().
Forum: C May 11th, 2007
Replies: 11
Views: 2,502
Posted By ~s.o.s~
Use the options suggested in posts 2 and 3.
Forum: C May 11th, 2007
Replies: 11
Views: 2,502
Posted By ~s.o.s~
I guess no:



<edit>Beaten..</edit>
Showing results 1 to 40 of 618

 


About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC