linux list application installation

C++
Use this command on ubuntu:
> sudo dpkg --listfiles [appname]
Source

Also in C++: