だから私は基本的なコンピュータプログラムを書こうとしています。そして、いくつかの構文で少し問題があります。コードは次のとおりです。
@echo off
cls
color 71
:start
echo -----------------------------------
echo Welcome to Tandy's Calculator! v0.1
echo -----------------------------------
echo Enter your first number below
echo Type "help" to see the list of available commands
echo -----------------------------------
set /p "_input1=Please Enter The First Number or Command:"
cls
goto subroutine
:subroutine
:: the below line gives me the "goto was unexpected at this time" error
if /i "%_input1%"=="help" goto help1
if /i "%_input1%"=="back" goto _input1
if /i "%_input1%"=="clear" goto clearVar (
goto checkVar
)
ファイルを実行するたびに、「goto は現時点では予想外でした」というエラーが表示され、コマンド ウィンドウが閉じます。
一時停止コマンドを使用して、エラー メッセージが表示されるプログラムの部分を特定できました。これは番組内でコメント済み。
誰でも私を助けることができますか?構文の何が問題になっていますか?