filmov
tv
LeetCode | 355. Design Twitter | HashMap | Vector

Показать описание
Design a simplified version of Twitter where users can post tweets, follow/unfollow another user, and is able to see the 10 most recent tweets in the user's news feed.
Implement the Twitter class:
Twitter() Initializes your twitter object.
void postTweet(int userId, int tweetId) Composes a new tweet with ID tweetId by the user userId. Each call to this function will be made with a unique tweetId.
getNewsFeed(int userId) Retrieves the 10 most recent tweet IDs in the user's news feed. Each item in the news feed must be posted by users who the user followed or by the user themself. Tweets must be ordered from most recent to least recent.
void follow(int followerId, int followeeId) The user with ID followerId started following the user with ID followeeId.
void unfollow(int followerId, int followeeId) The user with ID followerId started unfollowing the user with ID followeeId.
#leetcode #dsa #hashmap #vector
Implement the Twitter class:
Twitter() Initializes your twitter object.
void postTweet(int userId, int tweetId) Composes a new tweet with ID tweetId by the user userId. Each call to this function will be made with a unique tweetId.
getNewsFeed(int userId) Retrieves the 10 most recent tweet IDs in the user's news feed. Each item in the news feed must be posted by users who the user followed or by the user themself. Tweets must be ordered from most recent to least recent.
void follow(int followerId, int followeeId) The user with ID followerId started following the user with ID followeeId.
void unfollow(int followerId, int followeeId) The user with ID followerId started unfollowing the user with ID followeeId.
#leetcode #dsa #hashmap #vector
Design Twitter - Leetcode 355 - Python
355. Design Twitter | LEETCODE MEDIUM | HASH TABLE | DESIGN | DATA STRUCTURES
LeetCode | 355. Design Twitter | HashMap | Vector
Design Twitter - Leetcode 355 - Python
Leetcode Question 355 'Design Twitter' in Java
Design Twitter - LeetCode #355 - C++
Leetcode 355 Design Twitter
L-8 leetcode 355. Design Twitter | heaps | leetcode daily challenge | Java DSA | Hindi
LeetCode - Design Twitter - C++
LEETCODE 355 - Design Twitter
Design Twitter - System design | leetcode
No Sound Leetcode 355: Design Twitter
355. Design Twitter - JavaScript - Easy To Understand
LeetCode 355 | Design Twitter | OOP | HashMap | Java
Pass Leetcode #355 Design Twitter
Design Twitter - System Design Interview
Design Twitter LeetCode
Design Twitter - System Design Interview Question
LeetCode Medium: 355. Design Twitter
Leetcode #355: Design Twitter #leetcode #leetcodepython #studycoding #python #coding #programming
Design Twitter Neetcode150 Series (69 of 150) Leetcode - Second Run
65. Leetcode 355. Design Twitter : Javascript
LeetCode Design Problems (Part 2) | Design Twitter
LeetCode 355 Design Twitter
Комментарии