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

SmartX #34

Open
Amybiubiu opened this issue Apr 21, 2021 · 2 comments
Open

SmartX #34

Amybiubiu opened this issue Apr 21, 2021 · 2 comments
Labels

Comments

@Amybiubiu
Copy link
Owner

Amybiubiu commented Apr 21, 2021

一面

受到了无尽的打击,总有我准备不完的东西,脑子已经装不下那么多东西了,以及每天都在准备知识上的复习,实操上惨不忍睹。最可怕的是网上的唯一一篇面经,前两道题和我一样,当时瞄了一眼 promise 和 一个函数,看上去不是很难的样子,没在意,而且整个上午人也很焦虑,学不进去了,后果就是 promise 失败 + 1,拒信 + 1。

  • (没有自我介绍,直接上来两道题) 题目一
setTimeout(() => {
    console.log(1)
  }, 0);
  
  const promise = new Promise((resolve, reject) => {
    console.log(2)
    reject(3)
    console.log(4)
  })
  
  promise
  .then(() => console.log(5))
  .catch(() => console.log(6))
  .then(() => {
    console.log(7)
    return new Promise((resolve, reject)=>{
        reject(11);
    })
  })
  .catch(() => console.log(8))
  .then(() => console.log(9))
  
  console.log(10)
  • 题目二
const fn = (...args) => {
    let num = [];
    let str = '';
    for (let i = 0; i < args.length; i++) {
        console.log(args[i]);
        if(i === 0){
            str = args[0];
        }else{
            num.push(args[i]);
        }
    }
    let res = '';
    for(let i = 0; i < num.length; i++){
        res += num[i];
        // if(i !== num.length - 1){
            res += str[i+1];
        // }
    }
    res.slice(0, res.length);
    console.log(res);
    console.log('2+2+3=7');
  };
  const [a, b, c] = [2, 2, 3];
//   fn`'a' + ${a} + ${b} + ${c}= ${a + b + c} + 'n'`;
fn`${a} + ${b} + ${c}= ${a + b + c}`;
  • linux 命令 如何重命名文件、如何登陆ssh、如何两台主机互相消息传递
  • git 命令 git rebase 和 git pull 的区别
  • graphql 和 restful 比较一下?现在有一种 type 为 student 和一种 type 为 teacher 如何查询以及查询后的区分(resolver alias)
  • (项目一)一段字符串 a 中高亮出 b,怎么做?
  • (项目二)你的项目难点就是调了几个 web API ?如何处理平台的差异?(权限请求)也就是一个 web API 解决了咯?
  • (项目三)受控组件和非受控组件你讲一下?
  • 反问(提到了他们的 storyTeller 产品)

二面(二面体验感好好,好想去这家公司,能不能给我个机会呜呜呜,不过最近宿舍网好差,有时声音都在卡)

  • (再次不用自我介绍)看了面试官(都不知道上位面试官会给出什么样的评价……)和hr这边的评价后……你说一下你觉得挑战比较大的事情,可以是项目中,也可以是别的?
  • 你期望在实习中获得什么?(还是你怎么选择一个公司?)
  • Taro 跨端,你知道他是怎么做的吗?Taro 这边是写了很多测试代码……你项目中写过测试代码吗?
  • react 的优缺点
  • 看一道题 实现 JSON.stringfy (居然是我说思路,他写代码,有种代码自动生成的梦幻体验)
  • 你为什么想到要参加那个开源活动?
  • 反问1 问了实习生的工作,然后他详细介绍了他们公司的业务(私有云,介绍了公有云和私有云)、工作线(主线负责对外业务、内线做一些新方案的尝试、开源线把内部比较好的实践方案开源出来)
  • 反问2 学习前端的建议。他建议1、不要把自己局限于前端,在初期。2、长期维护/跟进一个项目 3、可以做一些别人做不了的事,比如某个feature,网上还没有做过;比如某个方案已有但有问题(他说 gatsby 奇慢无比,我羞愧于我不知道),想他为什么会有这样的问题以及如何解决。这些工作,不一定说要产生什么商业效应,它可以是你觉得他很值得,他很有挑战性,哪怕他目前没人用,可是之后在某个工作场景那些经验都会是有用的。(我居然在听完这些之后再次燃起了技术热情(之前由于天天面试被浇灭了),想要好好学习,做更多更好的事情)
@Amybiubiu
Copy link
Owner Author

暂时没有拒信,约了二面,计划滚回来订正。。。

@Amybiubiu
Copy link
Owner Author

Amybiubiu commented Apr 23, 2021

let total = 30;
let msg = passthru`The total is ${total} (${total*1.05} with tax)`;

function passthru(literals) {
  let result = '';
  let i = 0;

  while (i < literals.length) {
    result += literals[i++];
    if (i < arguments.length) {
      result += arguments[i];
    }
  }

  return result;
}

msg // "The total is 30 (31.5 with tax)"

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

No branches or pull requests

1 participant