Search Results

Showing results 1 to 35 of 35
Search took 0.01 seconds.
Search: Posts Made By: tymk
Forum: JavaScript / DHTML / AJAX May 19th, 2009
Replies: 1
Views: 557
Posted By tymk
The position and visibility of the image element is dynamically updated.

The following code displays the correct dimensions in Firefox 3.0.10 and Chrome 1.0.154.65, but displays "0,0" in IE8.

...
Forum: C++ Jan 19th, 2009
Replies: 5
Views: 385
Posted By tymk
I think you need to set resident[i-1]->next in here somewhere.
Forum: C++ Dec 30th, 2008
Replies: 8
Views: 737
Posted By tymk
Ah, ok, I get it now. Thank you for all of your help!
Forum: C++ Dec 29th, 2008
Replies: 12
Solved: cin.ignore
Views: 1,153
Posted By tymk
cin.ignore(this post);
Forum: C++ Dec 29th, 2008
Replies: 8
Views: 737
Posted By tymk
Thanks, this is much more honest, direct, informative and helpful than "It's cool!"

OK, now I see what you mean.

I understand eliminating the using std::string but I don't understand...
Forum: C++ Dec 27th, 2008
Replies: 8
Views: 737
Posted By tymk
Thanks, this is exactly the type of feedback I'm looking for.

Really? Is this one of your defects? If so, why?


I suppose I took the lazy way out. I got as far as thinking I could make...
Forum: C++ Dec 27th, 2008
Replies: 8
Views: 737
Posted By tymk
Thank you. Yes, a non-generic name member was my intent for this excercise. I wanted to start with something simple before I tackle a larger project. One thing I overlooked was error handling. Not...
Forum: C++ Dec 27th, 2008
Replies: 8
Views: 737
Posted By tymk
Hi all. I wanted to run this class by some experienced programmers to see if I have any obvious errors and to get any advice otherwise.
I created a test suite and everything seems to function...
Forum: C++ Jul 14th, 2008
Replies: 13
Views: 1,292
Posted By tymk
My favoritest book has been C++ : how to program / H.M. Deitel, P.J. Deitel.
Forum: C++ Apr 27th, 2008
Replies: 9
Views: 3,339
Posted By tymk
Thanks for the info. That is unfortunate, but the Linux (note spelling, you had a typo) OS I am using is free, so I can't complain too much about it. And like I said, it is adequate for what I am...
Forum: C++ Apr 27th, 2008
Replies: 9
Views: 3,339
Posted By tymk
Yeah, I finally opened my eyes and stopped being lazy about it. I ran this exact code: (;) Dave...):

#include <ctime>
using std::clock;
#include <iostream>
using std::cout;

int main()
{...
Forum: C++ Apr 26th, 2008
Replies: 9
Views: 3,339
Posted By tymk
Thanks. I thought of that, so I ran something like:

...
clock_t b,e
int a
b = clock();
cout << clock() << '\n';
cin a;
cout << clock() << '\n';
e = clock();
Forum: C++ Apr 24th, 2008
Replies: 15
Views: 1,609
Posted By tymk
I came up with these helper functions to convert a name to a number. Even with different capitalization, the same name will be the same number each time. You can then add these numbers together and...
Forum: C++ Apr 24th, 2008
Replies: 9
Views: 3,339
Posted By tymk
Running 64-bit Fedora 8 on HP laptop with AMD Turion 64bit/dual core, developing in Eclipse, compiling with g++. The clock(); function always returns 0. Any ideas why this is so? I have had no...
Forum: C++ Apr 14th, 2008
Replies: 8
Views: 731
Posted By tymk
Also, in your if block, all you really need to do in there is output your line and in either case you set index=0;, so you don't need the else... you can just set it outside the if block. Along with...
Forum: C++ Apr 14th, 2008
Replies: 8
Views: 731
Posted By tymk
What happens if you just remove the (index>0) from your test?
Forum: C++ Apr 14th, 2008
Replies: 8
Views: 731
Posted By tymk
Ok, starting to look through it... first thing i see is that you keep inputing strings into the variable "text" until the end of the file, so text will only have the last string in the file. Then you...
Forum: C++ Apr 14th, 2008
Replies: 8
Views: 731
Posted By tymk
Still haven't looked through the code but you might need to add some parens around all of your symbol tests (all the tests that are ||.
Forum: C++ Apr 14th, 2008
Replies: 8
Views: 731
Posted By tymk
For your utility to create the text files, I think you're excluding 'z', you might have to expand your rand() function a little. You don't need to bother with the stack in your file creation utility...
Forum: C++ Apr 14th, 2008
Replies: 10
Views: 2,252
Posted By tymk
I also noticed your pali function is defined to return a char, but you are really returning an int.
You may be too commited to this approach, but as an alternative, you could eliminate the need to...
Forum: C++ Apr 14th, 2008
Replies: 10
Views: 2,252
Posted By tymk
Take a look at this statement, what is it doing and what do you want it to do?
s[b]=test[c];. Also, what is the value of b the first time through the loop?
Forum: C++ Apr 13th, 2008
Replies: 4
Views: 524
Posted By tymk
I wouldn't include the remainder variable in main. You don't need to pass it into your function. I would make remainder an int and assign it in your div function. Instead of just calling your...
Forum: C++ Apr 13th, 2008
Replies: 2
Solved: Empty Arrays
Views: 623
Posted By tymk
you'll have to keep track of how many items are in the array, will be 0 when empty. Will add one when you Insert and subtract one when you Remove or Erase. Plus you already created the empty array...
Forum: C++ Apr 13th, 2008
Replies: 4
Views: 524
Posted By tymk
This looks like the formula for a recursive procedure, which is a procedure that calls itself. You have to be careful with recursive procedures because you risk going into an endless (until you run...
Forum: C++ Apr 13th, 2008
Replies: 22
Views: 1,526
Posted By tymk
Forum: C++ Apr 13th, 2008
Replies: 22
Views: 1,526
Posted By tymk
that looks right... and if that successfully weeds out the invalid index values , then you can eliminate the if statement altogether and just do your cout.
Forum: C++ Apr 13th, 2008
Replies: 22
Views: 1,526
Posted By tymk
Try entering -1.
Forum: C++ Apr 13th, 2008
Replies: 22
Views: 1,526
Posted By tymk
sorry, missed your last couple, you figured out the size-1 part, now look at the rest.
Forum: C++ Apr 13th, 2008
Replies: 22
Views: 1,526
Posted By tymk
Congratulations, but not quite there (really, really close though). You have the do--while in the right place, but the test is incomplete. What if someone enters -5? Also, what if the array size...
Forum: C++ Apr 13th, 2008
Replies: 42
Views: 4,862
Posted By tymk
Check your curly braces {}... if you have more than one line of code to run within an if or else, the code must be enclosed in {}. It is good practice to always use these, even if you have a single...
Forum: C++ Apr 13th, 2008
Replies: 22
Views: 1,526
Posted By tymk
Good work! So now you 1) ask for input 2) if the input is in the desired range, output (otherwise do nothing). What you want to do is ask for input while input is not in the desired range, then...
Forum: C++ Apr 13th, 2008
Replies: 22
Views: 1,526
Posted By tymk
The way it is now, you effectively set j=0, then test if( 0 <= j && j < size ), which will always be true, since j will always be 0 at this point. You didn't need to add a new variable(j), you...
Forum: C++ Apr 13th, 2008
Replies: 10
Views: 916
Posted By tymk
Forum: C++ Apr 13th, 2008
Replies: 4
Views: 4,026
Posted By tymk
Do you use input somewhere else in the top part of your code, like to display what value was converted? If so, then you should leave it as a parameter to your conversion functions. Also looks like...
Forum: C++ Apr 12th, 2008
Replies: 5
Solved: class question
Views: 514
Posted By tymk
To answer your question... it is not working because (in your current design) when you say cin>> *sName; it is the same as saying cin>> sName[0];. The effect is overwriting the first person in the...
Showing results 1 to 35 of 35

 


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

©2003 - 2009 DaniWeb® LLC