~よりほか(は)ない/~ほかない
There is no choice but to …; can only …
N2
V dictionary form + よりほか (は) ない/ほか (は) ない/よりほかしかたがない
~ほかない says there is no other option, so one has to do it even if unwilling ({自分|じぶん}でやるほかない). It follows the dictionary form; 「よりほかない」, 「ほかはない」 and 「よりほかしかたがない」 mean the same. It is more formal and written than N3 「~しかない」 and close to 「~ざるを{得|え}ない」. The subject is usually the speaker; do not confuse it with 「~ないわけにはいかない」 (cannot avoid doing because of duty or social reasons).
Examples
終電を逃してしまったので、タクシーで帰るよりほかない。
I missed the last train, so I have no choice but to take a taxi home.
部品が届かない以上、今日の生産は止めるほかない。
As long as the parts don't arrive, we can only stop today's production.
誰も手伝ってくれないなら、自分でやるほかはない。
If no one will help, I'll just have to do it myself.
Exercises
1.大雪で電車が全部止まってしまった。今日は会社に泊まる 。
2.予算が足りない以上、計画を小さくする 。