GithubHelp home page GithubHelp logo

Comments (4)

huluoyang avatar huluoyang commented on May 1, 2024 15

@18101876465
arr=arr.push(item); //此时的arr为数组追加条目后的长度,并不是一个数组,自然没有shift方法。
说明你对数组的常用方法和返回值没有搞清楚,建议多练习。

function queue(arr, item) {
  // Your code here
  arr.push(item);  // 入队
  var result = arr.shift(); // 出队
  return result;  // 返回结果
}

from freecodecamp.cn.

18101876465 avatar 18101876465 commented on May 1, 2024 1

谢谢你

from freecodecamp.cn.

skyejy avatar skyejy commented on May 1, 2024

一语惊醒梦中人,多谢

from freecodecamp.cn.

qdchenyixuan avatar qdchenyixuan commented on May 1, 2024

这貌似是FCC中文社区的创始人,666

from freecodecamp.cn.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.