Smart working (client Pixel Pixel) vuejs

 

1st round virtual wedsite (not in person)

1. key features in vue.js

“Vue.js is known for being lightweight, approachable, and flexible. One of its key features is the reactive data binding system, which automatically updates the DOM when the data changes. It also has a component-based architecture that makes the UI modular and reusable.

Vue’s single-file components are great because you can keep template, script, and style in one file. It also supports directives like v-if, v-for, and v-model for binding and conditionals, which makes templating very powerful.

Another big advantage is Vue’s ecosystem—things like Vue Router for routing and Vuex or Pinia for state management. And it’s easy to integrate Vue into existing projects, which makes it very practical.

2.  Advantages and challenges in scss

One of the big advantages of SCSS is that it makes CSS more powerful and maintainable. I really like features like variables for reusing values, nesting for cleaner structure, and mixins for writing reusable code—especially for things like media queries or vendor prefixes. It helps keep styles organized in larger projects.

The main challenge, though, is that if you overuse nesting or mixins, the final CSS can get bloated or too specific, which makes it harder to maintain. Also, since SCSS needs to be compiled, it requires a build setup, which can be overkill for smaller projects. But overall, I think it’s a great tool when used wisely

2nd round (not in person)

 Multiple choice

1. which is conditional statement  i)v-if , ii)v-for  iii)v-bind

2.looping derivative  i)v-if , ii)v-for  iii)v-bind

3.event derivative in vue i)v-if , ii)v-for  iii)v-bind iv)@input

4. which is reactive variable declaration with vue3  i) let temp = reactive({ count: 0 })

5.how to pass data from parent to child?  i)props ii)emit

 JS coding
1) max profit in trading 

 from an array input 10 12 9 11 12 output = 3 
    9 sold at 12-9 = 3,
   input = 7 6 4 3 1 9 , output = 8

 ans)
function getMaxProfit(prices) {
  let minPrice = prices[0];
  let maxProfit = 0;

  for (let i = 1; i < prices.length; i++) {
    if (prices[i] < minPrice) {
      minPrice = prices[i];
    } else {
      const profit = prices[i] - minPrice;
      if (profit > maxProfit) {
        maxProfit = profit;
      }
    }
  }

  return maxProfit;
}

// Example usage:
console.log(getMaxProfit([10, 12, 9, 11, 12])); // Output: 3
console.log(getMaxProfit([7, 6, 4, 3, 1, 9]));   // Output: 8

Apptitude: question like
1.train speed and travel time
2. number of employees worked

Comments

Popular posts from this blog

insightsoftware vue js

Apexon React.js Interview

TCS vue js