黃彥軒
    • Create new note
    • Create a note from template
      • Sharing URL Link copied
      • /edit
      • View mode
        • Edit mode
        • View mode
        • Book mode
        • Slide mode
        Edit mode View mode Book mode Slide mode
      • Customize slides
      • Note Permission
      • Read
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Write
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Engagement control Commenting, Suggest edit, Emoji Reply
    • Invite by email
      Invitee

      This note has no invitees

    • Publish Note

      Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

      Your note will be visible on your profile and discoverable by anyone.
      Your note is now live.
      This note is visible on your profile and discoverable online.
      Everyone on the web can find and read all notes of this public team.
      See published notes
      Unpublish note
      Please check the box to agree to the Community Guidelines.
      View profile
    • Commenting
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
      • Everyone
    • Suggest edit
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
    • Emoji Reply
    • Enable
    • Versions and GitHub Sync
    • Note settings
    • Note Insights New
    • Engagement control
    • Make a copy
    • Transfer ownership
    • Delete this note
    • Save as template
    • Insert from template
    • Import from
      • Dropbox
      • Google Drive
      • Gist
      • Clipboard
    • Export to
      • Dropbox
      • Google Drive
      • Gist
    • Download
      • Markdown
      • HTML
      • Raw HTML
Menu Note settings Note Insights Versions and GitHub Sync Sharing URL Create Help
Create Create new note Create a note from template
Menu
Options
Engagement control Make a copy Transfer ownership Delete this note
Import from
Dropbox Google Drive Gist Clipboard
Export to
Dropbox Google Drive Gist
Download
Markdown HTML Raw HTML
Back
Sharing URL Link copied
/edit
View mode
  • Edit mode
  • View mode
  • Book mode
  • Slide mode
Edit mode View mode Book mode Slide mode
Customize slides
Note Permission
Read
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Write
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Engagement control Commenting, Suggest edit, Emoji Reply
  • Invite by email
    Invitee

    This note has no invitees

  • Publish Note

    Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

    Your note will be visible on your profile and discoverable by anyone.
    Your note is now live.
    This note is visible on your profile and discoverable online.
    Everyone on the web can find and read all notes of this public team.
    See published notes
    Unpublish note
    Please check the box to agree to the Community Guidelines.
    View profile
    Engagement control
    Commenting
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    • Everyone
    Suggest edit
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    Emoji Reply
    Enable
    Import from Dropbox Google Drive Gist Clipboard
       Owned this note    Owned this note      
    Published Linked with GitHub
    • Any changes
      Be notified of any changes
    • Mention me
      Be notified of mention me
    • Unsubscribe
    # 解決任何白板面試問題的6步驟 作者:David Yang 影片連結:{https://www.youtube.com/watch?v=DIR_rxusO8Q&t=917s} ## REACTO 6步驟法 ![image](https://hackmd.io/_uploads/ryMvLDR3R.png) ### R:重述問題 (Repeat the Question) >在面試中,許多應徵者一聽到問題就開始寫代碼,這可能導致錯誤的方向。你應該首先重述問題,確保你理解問題的每個細節。這樣做可以讓你有機會與面試官討論你不理解的部分,確保雙方在同一個起點上。 >重述問題有助於: >> 一、更深入理解問題。 >> 二、可以在重述過程中,和面試者討論或確認,問題中你不理解的部分。 >> 三、確保作法的第一步是正確的。 ### E:列舉範例 (Write Out Examples) >在開始編寫任何代碼之前,先寫出輸入和輸出的範例。建立一個兩欄的表格來展示輸入參數和預期的輸出結果。這樣可以幫助你更好地理解問題,並且與面試官保持對話,確認你是否正確理解了問題。 > >作法 : 劃出一個兩到三個欄位的表格,填入個參數的輸入與輸出。 ### A:描述方法 (Describe Your Approaches) > >闡述你的做法,並觀察面試官的反應,可以知道你選擇的方法是否有問題。 > >影片中這樣說 : you're playing the interviewer a little bit as well as playing the question。 ### C:編寫代碼 (Write Your Code) >建議使用「廣度優先編程法」(Breadth-first Coding)。 > >將你的解決方法分解為高層次的功能,再逐步下移至細節層次,而不是直接進入具體的實作。 > >比免馬上編寫迴圈,先將步驟分解成高層次的函數,再逐步細化細節。這樣可以避免陷入細節問題而浪費時間,例如處理正規表達式或變量命名。 > >例如,正規表達式(regex)就是一個典型的例子。你可能會花大量時間去調試正規表達式。我個人經常在寫正規表達式時,花很長時間才能讓它正確運行。你也很容易被迴圈的邊界問題困住,或者變量命名上耗費太多時間。然而,當你仍在從高層次向下細化解決問題時,這些細節往往不值得花費太多精力。 > >如果你的整體方法是正確的,核心算法沒問題,那麼你所寫的CODE,面試官可能甚至不會要求你真正去實作這部分,因為他們會假設你知道這一步該做什麼。此時,底層細節變得不那麼重要了。 #### 小提醒: >>- 展示你的信心水平 >>>清楚表達你很肯定的部分,可以加上一個星號並說:「我很確定這個函數是這樣工作的」或「我很確定這是 array reduce 的參數」。同時,對那些你不太確定的部分加上星號。 >>> >>>這樣做可以向面試官展示你的**信心水平**,讓他們了解你對不同部分的把握程度。如果你對某些部分半信半疑但沒有表達出來,可能會讓面試官覺得你對整體代碼不夠了解。 >>> >>- 使用偽代碼 >>>在面試中,使用偽代碼是完全可以接受的。 >>> >>>大多數好公司或優秀的面試官不會關注你是否掌握了所有的 JavaScript 語法,他們更想看到你的思維方式,想了解你如何拆解一個問題。因此,如果有些代碼片段的語法你無法立即記起來,不妨用偽代碼寫出來。 >>> >>>例如,你可能將代碼分解為三個主要部分,其中有一個函數的語法你無法立刻記起來,那就直接用英語或其他方式描述這段功能,等到稍後再具體實作。 ### T:測試代碼 (Test the Code) >寫完代碼後,用你先前列出的範例來測試你的代碼。這可以展示你對細節的關注,並檢查算法是否如預期運行。在測試時,使用不同顏色的標記來跟踪變量的值變化,這有助於你和面試官了解代碼的執行流程。 ### O:優化代碼 (Optimization) >最後一步,也是最重要的一步,這一步往往能讓你與別人區分開來。 > >優化是在探討:這個算法在面對大數據集時表現如何?或者這個算法在不同類型和不同大小的數據集下會如何表現? > >這裡會涉及到我們常聽到的「大O符號」(Big O notation),例如 O(N)、O(N²)、O(M*N) 等等。也許你採用了暴力解法,也許你採用了迭代方法,因此這一部分會涉及到如何估算大O符號。雖然這裡不打算深入討論大O符號的詳細內容,但當你逐漸理解大O的時候,你可以指定:「這是我對優化的想法,我認為這個迴圈和內部迴圈會給我 O(N²) 的運行時間。」這展示了你有能力從生產環境的角度來考慮,如果將這段代碼投入到實際的代碼庫中,會發生什麼情況。 ## 其他建議與技巧 1. **保持冷靜**: 問題是專門設計讓人難以立刻解決的,面試官並不期待你能迅速找到正確答案。重點是展示你的問題分解能力和思維過程,而不是直接解答出問題。 2. **避免沉默**: 在面試中,保持與面試官的對話非常重要。即使你感覺自己陷入困境,也應該不斷 verbalize 你的思維過程。這不僅能幫助你保持冷靜,也能讓面試官對你留下良好印象。 3. **不要急於動筆**: 許多應徵者一拿到問題就立刻開始編寫代碼,這很容易導致走錯方向。你應該先重述問題、列舉範例並描述你的方法,然後再開始編寫代碼。這樣做可以為你節省很多時間,並避免錯誤的路徑。 4. **持續與面試官對話**: 讓面試變得像一場對話一樣,自然地交流你的思維過程,而不是機械地使用REACTO框架。這能幫助你在緊張的面試環境中保持流暢的思考。 ## 重點統整 1. **「不要一開始就急於動手寫code!」** >你的大腦在多個層次上運作,而一旦你開始寫代碼,就會自動把自己帶入可能錯誤的路徑。 > >你應該給自己更多的時間思考,讓你的大腦有時間調用你練習過的、學習過的所有知識。給你的潛意識一點時間,讓它在你開始動手寫代碼之前,將這些知識調入記憶中。因為一旦你開始寫代碼,你會不自覺地承諾走上一條可能錯誤的路徑。 2. **「你應該開始與面試官進行對話!」。** >當對話開始流暢起來後,當你進行編碼時,持續對話會變得更容易。 > >例如你可以說:「我在這裡有點卡住了,但如果我回想一下我之前描述的方法,可能應該這樣做,我需要找到基準情況,或者我需要弄清楚遞歸步驟。」對話一旦開始,就可以繼續進行。 3.**「保持冷靜。你不需要馬上知道答案!」** >這些問題設計是為了讓你花一些時間思考並解決,把注意力放在問題的分解。 >如果你不知道答案,或不懂得這個技巧,那麼在一個緊張的情況下,你不太可能馬上想到正確解法。 >白板提並不是要測試你能在30分鐘的面試中弄懂所有計算機科學知識,而是測試你是否曾接觸過這些信息。即使接觸過,你仍然需要能夠回想起來、實現它並執行它。 > >不要太過緊張,覺得你必須要立刻搞懂所有東西。有時候不知道答案是可以的。即使你沒能解出答案,你仍然可以找到一份工作。 4. **「保持對話,試圖 verbalize(用語言表達)你腦海中的思維過程。」** >人類的本能反應:當房間裡沒有人說話時,氣氛會非常尷尬。 > >當你專心在思考時,很難注意到這點,但你的面試官會坐在那裡想:「我不想和這個人在一起工作,因為每次他們遇到困難時,他們都只會坐在那裡讓我感到不自在。」

    Import from clipboard

    Paste your markdown or webpage here...

    Advanced permission required

    Your current role can only read. Ask the system administrator to acquire write and comment permission.

    This team is disabled

    Sorry, this team is disabled. You can't edit this note.

    This note is locked

    Sorry, only owner can edit this note.

    Reach the limit

    Sorry, you've reached the max length this note can be.
    Please reduce the content or divide it to more notes, thank you!

    Import from Gist

    Import from Snippet

    or

    Export to Snippet

    Are you sure?

    Do you really want to delete this note?
    All users will lose their connection.

    Create a note from template

    Create a note from template

    Oops...
    This template has been removed or transferred.
    Upgrade
    All
    • All
    • Team
    No template.

    Create a template

    Upgrade

    Delete template

    Do you really want to delete this template?
    Turn this template into a regular note and keep its content, versions, and comments.

    This page need refresh

    You have an incompatible client version.
    Refresh to update.
    New version available!
    See releases notes here
    Refresh to enjoy new features.
    Your user state has changed.
    Refresh to load new user state.

    Sign in

    Forgot password

    or

    By clicking below, you agree to our terms of service.

    Sign in via Facebook Sign in via Twitter Sign in via GitHub Sign in via Dropbox Sign in with Wallet
    Wallet ( )
    Connect another wallet

    New to HackMD? Sign up

    Help

    • English
    • 中文
    • Français
    • Deutsch
    • 日本語
    • Español
    • Català
    • Ελληνικά
    • Português
    • italiano
    • Türkçe
    • Русский
    • Nederlands
    • hrvatski jezik
    • język polski
    • Українська
    • हिन्दी
    • svenska
    • Esperanto
    • dansk

    Documents

    Help & Tutorial

    How to use Book mode

    Slide Example

    API Docs

    Edit in VSCode

    Install browser extension

    Contacts

    Feedback

    Discord

    Send us email

    Resources

    Releases

    Pricing

    Blog

    Policy

    Terms

    Privacy

    Cheatsheet

    Syntax Example Reference
    # Header Header 基本排版
    - Unordered List
    • Unordered List
    1. Ordered List
    1. Ordered List
    - [ ] Todo List
    • Todo List
    > Blockquote
    Blockquote
    **Bold font** Bold font
    *Italics font* Italics font
    ~~Strikethrough~~ Strikethrough
    19^th^ 19th
    H~2~O H2O
    ++Inserted text++ Inserted text
    ==Marked text== Marked text
    [link text](https:// "title") Link
    ![image alt](https:// "title") Image
    `Code` Code 在筆記中貼入程式碼
    ```javascript
    var i = 0;
    ```
    var i = 0;
    :smile: :smile: Emoji list
    {%youtube youtube_id %} Externals
    $L^aT_eX$ LaTeX
    :::info
    This is a alert area.
    :::

    This is a alert area.

    Versions and GitHub Sync
    Get Full History Access

    • Edit version name
    • Delete

    revision author avatar     named on  

    More Less

    Note content is identical to the latest version.
    Compare
      Choose a version
      No search result
      Version not found
    Sign in to link this note to GitHub
    Learn more
    This note is not linked with GitHub
     

    Feedback

    Submission failed, please try again

    Thanks for your support.

    On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?

    Please give us some advice and help us improve HackMD.

     

    Thanks for your feedback

    Remove version name

    Do you want to remove this version name and description?

    Transfer ownership

    Transfer to
      Warning: is a public team. If you transfer note to this team, everyone on the web can find and read this note.

        Link with GitHub

        Please authorize HackMD on GitHub
        • Please sign in to GitHub and install the HackMD app on your GitHub repo.
        • HackMD links with GitHub through a GitHub App. You can choose which repo to install our App.
        Learn more  Sign in to GitHub

        Push the note to GitHub Push to GitHub Pull a file from GitHub

          Authorize again
         

        Choose which file to push to

        Select repo
        Refresh Authorize more repos
        Select branch
        Select file
        Select branch
        Choose version(s) to push
        • Save a new version and push
        • Choose from existing versions
        Include title and tags
        Available push count

        Pull from GitHub

         
        File from GitHub
        File from HackMD

        GitHub Link Settings

        File linked

        Linked by
        File path
        Last synced branch
        Available push count

        Danger Zone

        Unlink
        You will no longer receive notification when GitHub file changes after unlink.

        Syncing

        Push failed

        Push successfully