Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Week 4. hw1計算機問題 #7

Open
AngeloETH opened this issue Jul 19, 2018 · 1 comment
Open

Week 4. hw1計算機問題 #7

AngeloETH opened this issue Jul 19, 2018 · 1 comment

Comments

@AngeloETH
Copy link

AngeloETH commented Jul 19, 2018

請問這題建議實作到什麼程度呢?
看了一下要實作整個google計算機有點難啊XD,發現這題可大可小
以下問題是我看了『學長』的作業並未實作出來的部分:
1.若簡易的加減乘除有含括號嗎? => 四則運算可能要用到stack dsa
2.需要實作負數嗎? => -2+3 的-2按不出來
3.如果我依次輸入 3 * 2 + 2 = 答案為4 => 正確應為6
會有這個issue是因為會糾結在一些功能的實現而延誤了整體學習的進度,例如糾結於 sin cos怎麼實作

@aszx87410
Copy link
Member

aszx87410 commented Jul 20, 2018

這題主要是考對 DOM 的熟悉度而已喔,所以你提到的都不用實做出來沒關係
可以假設輸入者一次只會輸入一個數字而且不會是負數
例如說:

  1. 30
  2. +
  3. 8
  4. =
  5. 顯示 38

只要能通過這最簡單的 case 就行了

但如果你是想額外練習的話,可以做到功能很豐富,可以參考 Google 的計算機

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants