How to stop displaying keyboard input on matlab command line

16 ビュー (過去 30 日間)
Happy Bear
Happy Bear 2020 年 3 月 4 日
回答済み: Jamuna 2020 年 3 月 4 日
I've developed a "game" on matlab which opens up a window, I play it using 2 different keys repeatedly and then the game ends and the window closes.
When the window closes, I can see all the letters corresponding to the keys that I played during the game, in the command line, smth like:
Is there any way for this not to be displayed on the command line or for it be deleted before the game window closes?
>> adaddadaddda
  1 件のコメント
KSSV
KSSV 2020 年 3 月 4 日
Check did you forget to terminate any line with ;.

サインインしてコメントする。

回答 (1 件)

Jamuna
Jamuna 2020 年 3 月 4 日
End the statement of keyboard input with semicolon
x = input(prompt);

カテゴリ

Help Center および File ExchangeNumber games についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by