check which users are part of a group linux

C++
grep 'group-name-here' /etc/group
Source

Also in C++: