我寫了一個函數,用於查找二叉樹的高度(即沿着從根到葉的最長路徑的節點數量)。 let rec height (t: 'a tree) : int =
begin match t with
| Empty -> 0
| Node (l, v, r) -> 1 + max (height 1) (height r)
end
我相信,我的功能是正確的,但是當我運行出現的語法錯誤我的測試說「這
我試圖驗證elemnt是否存在。我用ISVISIBLE但它引發的錯誤消息「類型錯誤:對象#有沒有方法‘可見性’」 it('should verify all the elements present',function(){
expect(manageUser.manageUserTitle.getText()).toMatch('Manage Users');
expect(