is the given structure a group is the below given structure a group??
[     *    e a b c d f g
  e    e a b c d f g
  a    a b e g c d f
  b    b e a f g c d
  c    c d f a e g b
  d    d f g e a b c
  f    f g c d b a e
  g    g c d b f e a     ]  if yes, then {e,a,b} will be subgroup, correct?

then wont it violate Lagrange's theorem. Please I am new to group theory.
 A: Yes, you're right: this can't be a group, because if it were, then $\{e, a, b\}$ would be a subgroup, which violates Lagrange's theorem. Note how useful Lagrange is here: it would be really frustrating to check by hand which group axiom is violated in the above structure! 
A: The composition is not associative, because
$$
(a\cdot b)\cdot c=c\neq d=a\cdot (b\cdot c).
$$
Hence the structure table does not define a group.
A: Or, using a bit more theory: $7$ is prime, so a group of order $7$ must be cyclic. But this group manifestly isn't.
A: To give a bit more info on this structure:


*

*It is a magma, because the operation is closed in $\{e,a,b,c,d,f,g\}$.

*It is a quasigroup, because every element appears in every row and column exactly once.

*It is a loop, because $e\ast x=x\ast e=x$ for each $x$.

*It is not a left Bol loop, because $a\ast(b\ast(a\ast c))=c\ne g=(a\ast(b\ast a))\ast c$.

*It is not a right Bol loop, because $((c\ast a)\ast b)\ast a=c\ne d=c\ast ((a\ast b)\ast a)$.

*(It follows from either of the last two that it is not a group.)

