2020年11月-北京-今日头条面试题

一面

  1. 常见的请求头,响应头
  2. http与https区别,https是怎样加密的
  3. 常见状态码,做什么用的
  4. vue的原理大致说下(我从响应式,虚拟dom,模版编译三个方面来回答的)
  5. vue首次渲染是在什么时候
  6. vue.$set原理
  7. vue中的key
  8. vue常见优化
  9. webpack的常见优化
  10. 讲一下对闭包的理解
  11. 算法题,合并两个升序数组
  12. 宏任务,微任务问题
const pro = new Promise((resolve, reject) => {
    const innerpro = new Promise((resolve, reject) => {
        setTimeout(() => {
            resolve(1);
        }, 0);
        console.log(2);
        resolve(3);
    });
    innerpro.then(res => console.log(res));
    resolve(4);
    console.log('pro');
})
pro.then(res => console.log(res));
console.log('end');

二面

  1. 介绍了之前做过的性能监控
  2. co模块
function a1(next){ 
  console.log('dosth_a1_before'); 
  next && next();
  console.log('dosth_a1_after');
}
function a2(next){
  console.log('dosth_a2_before');
  next && next(); 
  console.log('dosth_a2_after');
}
function a3(next){
  console.log('dosth_a3_before'); 
  next && next(); 
  console.log('dosth_a3_after');
}
function fn([a1,a2,a3]){
    
}

按如下顺序输出

dosth_a1_before ,
dosth_a2_before,
dosth_a3_before,
dosth_a3_after,
dosth_a2_after,
dosth_a1_after
  1. 顺时针打印矩阵

然后凉凉~

  • 2
    点赞
  • 3
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值