[英]Matlab - Access the output a function inside another function
我正在嘗試從另一個函數訪問一個函數的輸出。 我有以下功能:
function f = doSomething
f = 5+6;
在另一個函數中,我按如下方式調用doSomething:
doSomething;
有沒有辦法得到f
的值? 我想閱讀doSomething的輸出並顯示它。
寫
輸出= doSomething();
將結果存儲到變量“輸出”,並且
fprintf('%d \\ n',output);
顯示它。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.