Search:

Type: Posts; User: Tobias Mihel

Search: Search took 0.00 seconds.

  1. Replies
    3
    Views
    765

    Electrical network problem

    You are given the number of houses and the number of paths.

    Each path connects two houses with a given price (it connects both ways).

    You have to connect all the houses with the minimal cost. ...
  2. Replies
    6
    Views
    943

    #include #include using...

    #include<iostream>
    #include<conio.h>


    using namespace std;
    class item{
    public:
    char name[20];
    int price;
    void enter(int);
  3. Replies
    9
    Views
    1,069

    return 5 sorry i pasted wrong

    return 5 sorry i pasted wrong
  4. Replies
    9
    Views
    1,069

    ok i wrote it int rek(int i) { if(i>2) ...

    ok i wrote it


    int rek(int i)
    {
    if(i>2)
    return -2*rek(i-1)+rek(i-2);
    if(i==2) return i;
    else return 1;
    }
  5. Replies
    9
    Views
    1,069

    Yeah I tried but the sequence is really weird ...

    Yeah I tried but the sequence is really weird ...
  6. Replies
    9
    Views
    1,069

    That's all we were given and the maximum n-th...

    That's all we were given and the maximum n-th term to be searched for is 6 so it doesn't matter what follows
  7. Replies
    9
    Views
    1,069

    Recursive sequence

    We have a sequence of numbers "5,2,1,0,1,-2,5,...."
    Write a recursive function which returns the 6th number of this sequence.
    I have done recursive functions like fibonacci or pow but not something...
  8. Replies
    2
    Views
    2,336

    Overlapping squares

    How would i calculate a surface that up to 10^5 squares cover. The info you get is xpos,ypos and width for each square. How would you calculate the total surface covered (if any overlap only one...
  9. Replies
    3
    Views
    876

    I must solve that in code but I am wondering how...

    I must solve that in code but I am wondering how this would be done.
  10. Replies
    3
    Views
    876

    Basic combinatorics

    you have 3 integers given X,Y,Z
    X is amount of black soldiers
    Y is amount of purple soldiers
    Z is amount of white soldiers

    Calculate how many variations there are if black and white can't stand...
  11. Replies
    8
    Views
    1,372

    There are variations involved. I know how I would...

    There are variations involved. I know how I would calculate without the obstacles but I don't know how to take the obstacles into the equation or try another path. I just need a general idea how to...
  12. Replies
    8
    Views
    1,372

    C++ chess-like task

    So I got a task from our countries programming team to do this but I have no idea how I could go at it (I'm not looking for a solution in code but just how I could be able to do this in C++)

    So...
Results 1 to 12 of 12