FanCraze interview experience Real time questions & tips from candidates to crack your interview

Frontend Developer

FanCraze
upvote
share-icon
1 rounds | 2 Coding problems

Interview preparation journey

expand-icon
Application story
I came across a LinkedIn post that mentioned a hiring drive. The coding round was held at the Acciojob Skill Centre.
Preparation
Duration: 3 months
Topics: HTML, CSS, JavaScript, React.js, NodeJS
Tip
Tip

Tip 1: Focus on building conceptual clarity.
Tip 2: Practice by coding simple web pages.
Tip 3: Gain a deep understanding of the React.js framework to excel in frontend roles.

Application process
Where: Linkedin
Eligibility: 7 CGPA, (Salary Package - 5-7 LPA)
Resume Tip
Resume tip

Tip 1: Tailor your resume to the job profile.
Tip 2: Keep your resume concise and clear.

Interview rounds

01
Round
Medium
Online Coding Interview
Duration90 minutes
Interview date9 Oct 2024
Coding problem2

1. String Concatenation Bug

A social media company, InstaConnect, is building a new feature to allow users to share their favourite quotes. The feature is developed using React and JavaScript. The development team is using ES6 features to write more efficient and concise code. The quote-sharing feature requires a function to concatenate the user's name with the quote text. The function should take two parameters, userName and quoteText, and return a string in the format "userName: quoteText". The team is using arrow functions to implement this functionality. However, the function is not working as expected, and the QA team is reporting issues with the concatenated string.

Here is the code snippet:

const generateQuote = (userName, quoteText) =>
 userName + : + quoteText;
What is the mistake in the above code snippet, and how can it be corrected?

2. Sorting Logic Issue

A social media company, "SocialConnect", wants to develop a feature to display trending posts on their platform. They have a large dataset of posts and want to filter out the top 10 trending posts based on the number of likes. The development team has decided to use JavaScript for this task. They are using ES6 features to write efficient and concise code.

The team leader, Rachel, has written a function getTrendingPosts that takes an array of post objects as an argument and returns an array of the top 10 trending posts. The post object has properties like id, title, content, and likes. Rachel wants to use arrow functions to simplify the code.

Here is the code snippet:

const getTrendingPosts = (posts) => {
 // Sort the posts in descending order based on likes
 const sortedPosts = posts.sort((a, b) => b.likes - a.likes);
 
 // Filter out the top 10 trending posts
 const trendingPosts = sortedPosts.slice(0, 10);
 
 return trendingPosts;
};
What is wrong with this implementation?

Here's your problem of the day

Solving this problem will increase your chance to get selected in this company

Skill covered: Programming

What is recursion?

Choose another skill to practice
Similar interview experiences
company logo
SDE - 1
3 rounds | 7 problems
Interviewed by OYO
4656 views
0 comments
0 upvotes
company logo
SDE - Intern
2 rounds | 3 problems
Interviewed by Amazon
960 views
0 comments
0 upvotes
company logo
SDE - 1
2 rounds | 5 problems
Interviewed by Meesho
6450 views
0 comments
0 upvotes
company logo
SDE - 1
3 rounds | 9 problems
Interviewed by Salesforce
3451 views
0 comments
0 upvotes
Companies with similar interview experiences
company logo
Frontend Developer
3 rounds | 11 problems
Interviewed by Amdocs
2479 views
0 comments
0 upvotes