Skip to content

Latest commit

Β 

History

History
73 lines (53 loc) Β· 1.92 KB

File metadata and controls

73 lines (53 loc) Β· 1.92 KB

toy

🧸 Algorithm_Study

🌟 μ½”λ“œμŠ€ν…Œμ΄μΈ  Toy μ•Œκ³ λ¦¬μ¦˜ μŠ€ν„°λ””μž…λ‹ˆλ‹€!🌟
🌟 μ•Œκ³ λ¦¬μ¦˜λΏλ§Œ μ•„λ‹ˆλΌ μ½”μŠ€ κ³Όμ •μ—μ„œ ν•„μš”ν•œ 자료λ₯Ό μ„œλ‘œ κ³΅μœ ν•©λ‹ˆλ‹€! 🌟



πŸ‘‰ Rules

  1. λͺ¨λ“  그룹원듀이 λ°œν‘œλ₯Ό ν•©λ‹ˆλ‹€.
    const Algolithm_study = () => {
    let Presenters = ["μš°μ„±λ‹˜", "μ€μš±λ‹˜", "μ£Όν˜„λ‹˜", "μ˜ν˜Έλ‹˜", "μˆœκΈ°λ‹˜", "μœ μ›λ‹˜"];
    return Presenters.map(el => `Today's Presenter : ${el}`)
}


  1. μžμ‹ μ΄ μž‘μ„±ν•œ μ½”λ“œκ°€ μ•„λ‹ˆλΌ λ‹€λ₯Έ μ‚¬λžŒμ΄ μž‘μ„±ν•œ μ½”λ“œλ₯Ό λ°œν‘œν•˜κ³  μ—¬λŸ¬ λ°©λ©΄μ—μ„œ μ½”λ“œλ₯Ό λΆ„μ„ν•˜λŠ” μ‹€λ ₯을 ν‚€μ›λ‹ˆλ‹€.
const random_Pr = function (arr) {
    let presenters = arr.slice();

    for (let i = 0; i < arr.length; i++) {
      const whoAreYou = Math.floor(Math.random() * arr.length);
      let me = presenters[i];

      presenters[i] = presenters[whoAreYou];
      presenters[whoAreYou] = me;
    }

    return presenters;
  };
  
  const presenters = ["μš°μ„±λ‹˜", "μ€μš±λ‹˜", "μ£Όν˜„λ‹˜", "μ˜ν˜Έλ‹˜", "μˆœκΈ°λ‹˜", "μœ μ›λ‹˜"];
  const result = random_Pr(presenters)

  const study_Start = [
  `μš°μ„±λ‹˜ μ½”λ“œ=> ${result[0]} 당첨!` ,
  `μ€μš±λ‹˜ μ½”λ“œ=> ${result[1]} 당첨!` ,
  `μ£Όν˜„λ‹˜ μ½”λ“œ=> ${result[2]} 당첨!` ,
  `μ˜ν˜Έλ‹˜ μ½”λ“œ=> ${result[3]} 당첨!` ,
  `μˆœκΈ°λ‹˜ μ½”λ“œ=> ${result[4]} 당첨!` ,
  `μœ μ›λ‹˜ μ½”λ“œ=> ${result[5]} 당첨!`
  ]
  console.log(study_Start)


  1. μŠ€ν„°λ”” 그룹이 λλ‚œ ν›„μ—λŠ” 배운점, λŠλ‚€μ μ„ κΈ°λ‘ν•©λ‹ˆλ‹€!
class Review {
    constructor(name, date, content) {
        this.name = name
        this.date = date
        this.content = content
    }
}

const today_i_learned = new Review ("이름을 μ μ–΄μ£Όμ„Έμš”", "λ‚ μ§œλ₯Ό μ μ–΄μ£Όμ„Έμš”", "λ‚΄μš©μ„ μž…λ ₯ν•΄μ£Όμ„Έμš”")