Q. See question above. If these two women are, as is common nowadays not dressed with Tz'nius (decor), can I still take out a sefer and learn Torah next to them?
A. Shulchan Aruch (O.H. 75: 2) rules that one may not read the shema or recite any blessing, including any other expression that is considered a dovor shebekedusha or holy articulation, in front of a woman who is not dressed properly and even has her hair uncovered, including one's own wife. (Mishna Berura ibid 1).
On question 278 regarding if one should avoid learning Torah while one has to contemplate the ervos walking in front of you in the street or when driving in the Summer days. we wrote:
"Mogen Avrohom (85,2) quoting Talmud Shabbos 150a rules that it is permitted to think Torah thoughts in front of an ervoh or immodestly clad person, only verbalizing is prohibited. “Shomeah keoneh” or listening (to a brocho) is like answering, does not apply in the context of learning Torah. (see Avnei Tzion 2,8 in regards to writing divrei Torah facing an ervoh).
Horav Shlomo Miller Shlit”a commented in addition, that the windshield which is often tinted, although by itself it does not permit the articulation of words of kedusha, (see Mishna Berura 75,5 on ervoh beashoshis), it does provide a further added reason to be lenient and listen to a light Torah tape while driving safely."
However, in your case of seating between two women improperly dressed, if possible, you may just think in learning with closed eyes. I that is not an option and learning from a Sefer is required, Horav Shlomo Miller's Shlit'a opinion is that in need it is permitted.
Rabbi A. Bartfeld as revised by Horav Dovid Pam, Horav Aharon Miller and Horav Chanoch Ehrentreu Shlit'a.