#include <stdlib.h>
#include <time.h>
#include <cmath>
#include "vektor.h"

inline vektor::vektor (int X, int Y)
{
    x = X;
    y = Y;
}

inline void vektor::random(int X, int Y)
{
    srand (time(NULL));
    x = rand() % X;
    y = rand() % Y;
}

inline float vektor::hosszNegyzet()
{
    return x*x + y*y;
}

inline float vektor::hossz()
{
    return sqrt(x*x + y*y);
}

inline void vektor::null()
{
    x = 0;
    y = 0;
}
