Turkish army praises public role in thwarting coup