Thread: noob in need of master

  1. #1
    Registered User
    Join Date
    Jun 2005
    Posts
    15

    noob in need of master

    I am a newbie to programming
    I have read books, and am following the tutorial hare at cprogramming.

    unfortunately I tend to think a little to much on the strict guide lines side when I learn stuff

    What I need is someone who knows the C++ language inside and out and can tell me this works like that and there is no other way, or this goes here or there and if you put it here this will happen and if you put it there, that will happen.

    I apologize in advance for being to "needy" but I want to work on programms to. Actually I would like to work on games and stuff, and hopefully I will have something to offer this community afterwards.

  2. #2
    Sweet
    Join Date
    Aug 2002
    Location
    Tucson, Arizona
    Posts
    1,820
    Sure give me let's say 25/hr(U.S.) and I will do that for you.
    Woop?

  3. #3
    Programmer Frantic-'s Avatar
    Join Date
    Dec 2004
    Posts
    114
    give me 24.50/hr (US) and ill do t

  4. #4
    Banned
    Join Date
    Jun 2005
    Posts
    594
    Ill do it for free in my free time, but im by far not a master but i
    know enough to get me buy and im learning more everyday. I
    may beable to help you with alot of stuff.

    Private message me with a AIM, ICQ, or MSN screenname, and
    when i get home from work we can talk.

  5. #5
    Registered User mrafcho001's Avatar
    Join Date
    Jan 2005
    Posts
    483
    Ill help you in my free time also
    I don't know C++ "inside and out" but then again there isn't many that do.

    I would say i know a lot of C++ and ill help with all i can
    PM me AIM screen name

  6. #6
    Carnivore ('-'v) Hunter2's Avatar
    Join Date
    May 2002
    Posts
    2,879
    Just so you know, if you post your questions here on the forum, there are plenty of 'masters' who can and will help, as long as you ask smart questions:

    http://www.catb.org/~esr/faqs/smart-questions.html

    You will find that the advice of the community is usually better than that of an individual.
    Just Google It. √

    (\ /)
    ( . .)
    c(")(") This is bunny. Copy and paste bunny into your signature to help him gain world domination.

  7. #7
    FOX
    Join Date
    May 2005
    Posts
    188
    Quote Originally Posted by Hunter2
    Just so you know, if you post your questions here on the forum, there are plenty of 'masters' who can and will help, as long as you ask smart questions:

    http://www.catb.org/~esr/faqs/smart-questions.html

    You will find that the advice of the community is usually better than that of an individual.
    I agree.

    Most questions can be easily be answered by google or the search function in this message board. The answer is already out there most of the time, you just gotta know where to look.

    By the way, I suspect that Salem is a robot from the future.

  8. #8
    Registered User
    Join Date
    Apr 2003
    Posts
    2,663
    You will find that the advice of the community is usually better than that of an individual.
    And, then you don't have to worry about some pedophile trying to get a date with you.

    What I need is someone who knows the C++ language inside and out and can tell me this works like that and there is no other way, or this goes here or there and if you put it here this will happen and if you put it there, that will happen.
    This:

    hello world program

    works like that:

    Code:
    #include <iostream>  //this goes here
    using namespace std; //this goes there
    
    int main()
    {
    	cout<<"hello world"<<endl;  //if you put this here, that message will happen.
    	
    	return 0;
    }
    There is no other way.

    How'd I do?
    Last edited by 7stud; 06-18-2005 at 12:27 PM.

  9. #9
    Carnivore ('-'v) Hunter2's Avatar
    Join Date
    May 2002
    Posts
    2,879
    >>There is no other way.
    Well, if you want to be really nitpicky, you could also take off "using namespace std;" and use std::cout. Alternately, you could change using namespace std to using std::cout/using std::endl. You could also have main() take command-line arguments, modify the comments indefinitely, and of course, omit the return 0;. Depending on your compiler and whether you're running from the command line or from an IDE and whether you're running in debug mode or not, you may also wish to add a pausing mechanism at the end of the program.

    If you're willing to go outside the standard, you can also create a Windows non-console application and then manually allocate a console and use WriteFile (?) to display "hello world".

    How'd I do?

    j/k 7stud, I'm just being a smartass
    Just Google It. √

    (\ /)
    ( . .)
    c(")(") This is bunny. Copy and paste bunny into your signature to help him gain world domination.

  10. #10
    Registered User
    Join Date
    Jun 2005
    Posts
    15
    ok I 'll post question here

    My ultimate goal is to re vamp shadow run, it's a great game!

    but for now I need to know how to put together those little things I have learned and and I need a complete list of functions, operators and the similar.

    I took this code from the tutorials and modified, any feed back as to how to make it better?

    Code:
    #include <fstream>
    #include <iostream>
     #include <stdio.h>
    
    using namespace std;
    
    int main()
    {
       int thisisanumber;
      char str[10];
    
      //Creates an instance of ofstream, and opens example.txt
      ofstream a_file ( "example.txt", ios::app );
      // Outputs to example.txt through a_file
      a_file<<"This text will now be inside of example.txt 1234567890 \n";
    
      // Close the file stream explicitly
    
      //Opens for reading the file
      ifstream b_file ( "example.txt" );
      //Reads one string from the file
      b_file>> str;
      //Should output 'this'
      cout<< str <<"\n";
      // b_file is closed implicitly here
    
      cout<<"Please enter a number: ";
      cin>> thisisanumber;
      cin.ignore();
      cout<<"You entered: "<< thisisanumber <<"\n";
      a_file<<"You entered: "<< thisisanumber <<"\n";
      cin.get ();
          a_file.close();
      return 1;
    }

  11. #11
    Work in Progress..... Jaken Veina's Avatar
    Join Date
    Mar 2005
    Location
    Missouri. Go Imos Pizza!
    Posts
    256
    Well, I'd just like to comment on your opriginal post, first. In Programming, there is NEVER "one right way to do it and that's that." A lot of teachers, books, tutorials, may say that, but it's mostly their opinion and the opinions of those they learned from, etc. Of course it's not ALL opinion. There are so called "bad ways" to do things, or ways that may produce other unwanted effects.

    The key that I have found to programming is to make sure you know what you're doing. When you write a line of code, try to figure out exactly how it works, or at least pretty close. When you know how something works, it's infinitely easier to figure out how it may have not worked the way you expected, and finding problems will be much faster. If you come across something you don't know how to do, or you want to implement a function or something that you've never used before, do some research, ask questions, maybe even write a separate "test" program and see what kind of results you can get.

    Now, to your code....

    I've only recently begun using C++, but I've worked with C for a long long time, so I'm not an expert at C++ style iostreams. In the case of
    Code:
      b_file>> str;
    I don't know if that takes care of the extra '\n.' That could be something to look up.
    Other than that, I see nothing wrong with it.
    Code:
    void function(void)
     {
      function();
     }

  12. #12
    Registered User
    Join Date
    Jun 2005
    Posts
    15
    how do I declare system?

    std::system("date /t > example.txt");
    std::system("time /t >> example.txt");

  13. #13
    Work in Progress..... Jaken Veina's Avatar
    Join Date
    Mar 2005
    Location
    Missouri. Go Imos Pizza!
    Posts
    256
    System commands, I'm not too familiar with either. Sorry.
    Code:
    void function(void)
     {
      function();
     }

  14. #14
    Registered User MathFan's Avatar
    Join Date
    Apr 2002
    Posts
    190
    Quote Originally Posted by gothpunk
    how do I declare system?
    It's not a good idea to this with "system()". It's not compatible with all systems etc...

    try this:

    Code:
    #include <iostream>
    #include <time.h>
    
    using namespace std;
    
    int main()
    {
    	time_t date=time(NULL);
    	cout<<"Time is "<<ctime(&date)<<endl;
    }



    char str[10];
    //...
    //Reads one string from the file
    b_file>> str;
    You mean, read ten symbols from the file? Then you must do something like:

    Code:
    //declaring with one extra symbol (which is reserved for the '\0' element, which MUST terminate all char strings)
    char str[11];
    
    //reading ten symbols from file and putting them into our string
    b_file.read(str, 10);
    
    //assigning '\0' to the last element to terminate the string
    str[10]='\0';
    
    cout<<str<<endl;
    The OS requirements were Windows Vista Ultimate or better, so we used Linux.

  15. #15
    samurai warrior nextus's Avatar
    Join Date
    Nov 2001
    Posts
    196
    everyone has their own way or style to looking at problems and solving them. the more you program the more consistent you will be at choosing a solution to a problem you have. and you're in need of a master?..well, all masters are in need of students because sometimes the master does learn from the student...

    GL
    nextus, the samurai warrior

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. noob needs help!!!!:(
    By tykenfitz in forum C Programming
    Replies: 1
    Last Post: 07-10-2005, 08:49 AM
  2. Rtfm
    By XSquared in forum A Brief History of Cprogramming.com
    Replies: 4
    Last Post: 03-13-2003, 05:19 PM
  3. WANTED: Contest Master
    By kermi3 in forum A Brief History of Cprogramming.com
    Replies: 15
    Last Post: 01-23-2003, 10:15 PM