Search Results

Search found 63 results on 3 pages for 'lego69'.

Page 3/3 | < Previous Page | 1 2 3 

  • problem with script

    - by lego69
    I'm workin on C-Shell, can somebody help me find the bug, my script: #! /bin/tcsh -f cut -d" " -f2 ${1} | ./rankHelper script rankHelper: #! /bin/tcsh -f set line = ($<) while(${#line} != 0) cat $line set line = ($<) end file lines from which the data was sent: 053-3787837 038280083 052-3436363 012345678 053-3232287 038280083 054-3923898 033333333 052-2222333 012345678 052-1111111 012390387 I run it using: > ./rank lines why do I receive only one number 038280083 I thought cut must cut 2 field from all rows... thanks in advance for any help I expect to see second field from all rows from lines

    Read the article

  • possible solutions of the warning

    - by lego69
    Hello, I have a very large code, that's why I can't post here all my code, can somebody explain what might be a problem if I have an error incompatible pointer type and give me several ways to solve it, thanks in advance just small clarification: I'm workin with pointers to functions ptrLine createBasicLine(){ DECLARE_RESULT_ALLOCATE_AND_CHECK(ptrLine, Line); result->callsHistory = listCreate(copyCall,destroyCall); <-here result->messagesHistory = listCreate(copyMessage,destroyMessage); <-and here result->linesFeature = NULL; result->strNumber = NULL; result->lastBill = 0; result->lineType = MTM_REGULAR_LINE; result->nCallTime = 0; result->nMessages = 0; result->rateForCalls = 0; result->rateForMessage = 0; return result; } copyCall,destroyCall - pointers to functions /** * Allocates a new List. The list starts empty. * * @param copyElement * Function pointer to be used for copying elements into the list or when * copying the list. * @param freeElement * Function pointer to be used for removing elements from the list * @return * NULL - if one of the parameters is NULL or allocations failed. * A new List in case of success. */ List listCreate(CopyListElement copyElement, FreeListElement freeElement); definitions of the functions ptrCall (*createCall)() = createNumberContainer; void (*destroyCall)(ptrCall) = destroyNumberContainer; ptrCall (*copyCall)(ptrCall) = copyNumberContainer;

    Read the article

  • piping to variables

    - by lego69
    cut -d" " -f2 ${2} | $callsTo hello, can somebody please explain can I pipe the result of cut to variable callsTo, and how will it be stored, as the string or list?

    Read the article

  • Problem with "not declared in this scope" error

    - by lego69
    I've got: error a1 was not declared in this scope Can somebody please explain why this code causes that? quiz.h #ifndef QUIZ_H_ #define QUIZ_H_ #include "quiz.cpp" class A { private: int player; public: A(int initPlayer); ~A(); void foo(); }; #endif /* QUIZ_H_ */ quiz.cpp #include "quiz.h" #include <iostream> using std::cout; using std::endl; A::A(int initPlayer = 0){ player = initPlayer; } A::~A(){ } void A::foo(){ cout << player; } main function #include "quiz.h" int main() { quiz(7); return 0; } quiz function #include "quiz.h" void quiz(int i) { A a1(i); a1.foo(); }

    Read the article

  • c++ possible errors

    - by lego69
    hello I've got error a1 was not declared in this scope, can somebody please explain me my fault my header: #ifndef QUIZ_H_ #define QUIZ_H_ #include "quiz.cpp" class A { private: int player; public: A(int initPlayer); ~A(); void foo(); }; #endif /* QUIZ_H_ */ implementation of class functions: #include "quiz.h" #include <iostream> using std::cout; using std::endl; A::A(int initPlayer = 0){ player = initPlayer; } A::~A(){ } void A::foo(){ cout << player; } my main #include "quiz.h" int main() { quiz(7); return 0; } function quiz: #include "quiz.h" void quiz(int i) { A a1(i); a1.foo(); }

    Read the article

  • conversions in C++

    - by lego69
    I have this snippet of the code: header class A { private: int player; public: A(int initPlayer = 0); A(const A&); A& operator=(const A&); ~A(); void foo() const; friend A& operator=(A& i, const A& member); }; operator= A& operator=(A& i, const A& member){ i(member.player); return i; } and I have row in my code: i = *pa1; A *pa1 = new A(a2); at the beginning i was int how can I fix it, thanks in advance I have an error must be non-static function

    Read the article

  • question about copy constructor

    - by lego69
    I have this class: class A { private: int player; public: A(int initPlayer = 0); A(const A&); A& operator=(const A&); ~A(); void foo() const; }; and I have function which contains this row: A *pa1 = new A(a2); can somebody please explain what exactly is going on, when I call A(a2) compiler calls copy constructor or constructor, thanks in advance

    Read the article

  • transferring parameters in C++

    - by lego69
    hello, can I have this snippet of the code: C *pa1 = new C(c2); and I transfer it to another function: foo(pa1); what exactly do I transfer actual pointer or its copy, thanks in advance and can somebody give some info about in which cases info is copied, and in which I transfer actual pointer

    Read the article

  • why do I need virtual table?

    - by lego69
    I was looking for some information about virtual table, but can't find something easy to understand, can somebody give me good example(not from Wiki, please), with explanations, or link, thanks in advance

    Read the article

  • some links for graphics in C

    - by lego69
    hello to everyone, I'm looking for some tutorials which can teach about graphics on C, I tryed find it, but all I can find are discussions about special topics, I'm beginner, thanks in advance

    Read the article

  • from string to integer (scripts)

    - by lego69
    I have this snippet of the code: set calls = `cut -d" " -f2 ${2} | grep -c "$numbers"` set messages = `cut -d" " -f2 ${3} | grep -c "$numbers"` @ popularity = (calls * 3) + messages and error @ expression syntax what does it mean? grep -c returns number, am I wrong, thanks in advance in $numbers I have list of numbers, 2 and 3 parameters also contain numbers

    Read the article

< Previous Page | 1 2 3