mmm, if u want to know a bit more about our que, it is also used as a conjunction in complex sentences, which are called "oraciones subordinadas" in Spanish. For instance, "la otra noche mariana me dijo que no iba a poder venir a mi casa", in this case, the important thing is that mariana did tell me sth, so what goes after que is the dependant clause, we call it subordinación sustantiva, as it can be replaced by eso(referring to a noun), that. Therefore, "la otra vez mariana me dijo (eso)
Moving on to questions, we use qué when it comes to unspecific things, as an example: ¿qué prefieres? ¿que has entendido? ¿qué vas a hacer entonces? If i replace in ¿qué prefieres? ¿cuál prefieres? they are slightly different, as if i say qué prefieres, wt im referring to is what do u prefer, so i'm talking in general, if i say cuál prefieres?, im saying which one do u prefer? there might be some given options and i have to choose.
If i ask ¿que has entendido? im talking in general, wt have u understood(in english is more common to ask wt did u understand i think). And if i ask ¿cuál has entendido) once again some options might have been given and one has to choose.
with ¿qué vas a hacer entonces? it's the same case, wt im asking is wt are u going to do? can be anything. If i ask ¿cuál vas a hacer entonces? it's different, u have to choose(same as previous examples).