• InstaByte
  • Posts
  • China's open source AI beats OpenAI

China's open source AI beats OpenAI

ALSO: Why use Kafka?

In partnership with

Welcome back!

Amazon loves this week’s problem. Hope you enjoy the challenge!

Here’s what to expect today:

  • Longest substring without repeating characters

  • Why use Kafka?

Read time: under 4 minutes

CODING CHALLENGE

Longest Substring Without Repeating Characters

Given a string s, find the length of the longest substring without repeating characters.

Example 1:

Input: s = "abcabcbb"
Output: 3
Explanation: The answer is "abc", with the length of 3.

Example 2:

Input: s = "bbbbb"
Output: 1
Explanation: The answer is "b", with the length of 1.

Example 3:

Input: s = "pwwkew"
Output: 3
Explanation: The answer is "wke", with the length of 3.
Notice that the answer must be a substring, "pwke" is a subsequence and not a substring.

Solve the problem here before reading the solution.

PRESENTED BY NEO

AI help, without the trust tax.

Most AI tools ask you to trade your data for intelligence. Norton Neo doesn't. It's the first safe AI-native browser built by Norton, and it gives you powerful built-in AI without handing your privacy over to get it. Search, summarize, and write with AI built directly into your browser. Your data stays yours. Your context stays private.

Built-in VPN, anti-fingerprinting, and ad blocking come standard. No add-ons. No setup. No compromises.

Fast. Safe. Intelligent. That's Neo.

SOLUTION

To solve this problem, we'll use a sliding window approach with a dictionary. We'll keep track of the characters we've seen and their indices.

We'll move the right pointer of our window, adding characters to the dictionary. If we find a repeating character, we'll move the left pointer to the right of the last occurrence of that character.

We'll update the maximum length of the substring as we go.

The time complexity of this solution is O(n), where n is the length of the input string.

HEARD OF WISPR FLOW?

Say user_id. Get user_id.

Wispr Flow recognizes variable names, file references, and framework syntax mid-dictation. Speak your prompt, get developer-ready text for GitHub, Jira, or your editor. No mangled syntax. Ever.

SYSTEM DESIGN

Why Use Kafka?

Source: Daily Dose of Python on Medium

Apache Kafka is a distributed data streaming platform designed for high-throughput, real-time data processing. It is used to handle continuous streams of data from many different sources at the same time.

Key features of Kafka:

  1. Scalability: Kafka distributes data across multiple servers, allowing it to handle massive amounts of information beyond a single machine's capacity.

  2. Speed: With its decoupled write and read data streams, Kafka offers extremely low latency, making it ideal for real-time applications.

  3. Durability: Data is replicated across servers and written to disk, protecting against server failures.

  4. Flexible data retention: Kafka can store data for configurable periods, from seconds to years.

  5. Multiple consumer support: Unlike traditional message queues, Kafka allows multiple applications to read the same data stream independently.

Kafka's architecture combines messaging queue and publish-subscribe models. It organizes data into topics that are partitioned. The messages within a partition are processed in order.

Kafka is used to build real time data pipelines. For example, Uber drivers send their location to the server every few seconds. This location is added to a Kafka queue. From the queue, the location is read by different consumers for applications like matching drivers with riders or showing nearby drivers to the riders on the app.

FEATURED COURSES

5 Courses of the Week

✅ Generative AI Engineering with LLMs Specialization: Go beyond prompting and learn to engineer generative AI solutions using large language models, RAG pipelines, and fine-tuning techniques. Ideal for developers ready to build and deploy production-grade AI applications.

✅ Microsoft Azure Data Scientist Associate Professional Certificate: Train and deploy machine learning models on Microsoft Azure using Python, Azure ML Studio, and MLflow. This program prepares you for the DP-100 certification while building practical skills in cloud-based data science workflows.

✅ Algorithms Specialization: Sharpen your problem-solving skills with Stanford's rigorous four-course series covering sorting, graph algorithms, dynamic programming, and NP-completeness. A must-have for developers preparing for technical interviews or strengthening their CS fundamentals.

✅ Meta iOS Developer Professional Certificate: Learn to build polished, production-ready iOS apps using Swift, Xcode, and Apple's latest frameworks. This Meta-designed program takes you from core programming fundamentals to deploying apps on the App Store.

✅ IBM Data Analyst Professional Certificate: Launch your data analytics career with hands-on training in Excel, SQL, Python, and data visualization tools like Tableau and Cognos. Complete real-world projects and earn a professional credential recognized by top employers.

NEWS

This Week in the Tech World

Chinese Labs Ship Open Models: Moonshot released Kimi K2.7 Code while Zhipu shipped GLM-5.2, which offers a one million token context window for long autonomous coding, keeping China's open source push squarely in the AI race.

SpaceX Stages Record IPO: SpaceX priced shares at $135 and raised $75 billion, the biggest IPO ever, valuing Elon Musk's rocket maker near $1.75 trillion. Shares listed on the Nasdaq as SPCX and closed up 19 percent on debut.

SpaceX Snaps Up Cursor: Fresh off its blockbuster listing, SpaceX agreed to buy AI coding startup Cursor for $60 billion, its largest acquisition yet. SpaceX shares jumped about 16 percent on the news, lifting its market cap past Amazon and Microsoft.

Bezos Startup Lands $12B: Prometheus, the AI engineering and manufacturing startup co-led by Jeff Bezos, raised $12 billion in Series B at a roughly $41 billion valuation. Backers include JPMorgan, BlackRock, Goldman Sachs, DST Global and Arch Venture Partners.

Mistral Eyes €3B Raise: France's Mistral AI is in talks to raise about €3 billion from venture syndicates and sovereign wealth funds, a deal that would roughly double its valuation to €20 billion and cement its place among Europe's most valuable startups.

Nuvei to Buy Payoneer: Payments firm Nuvei agreed to acquire cross border payments company Payoneer in a $2.75 billion all cash deal, expanding its reach in global business payments.

ServiceNow Trims Hundreds: Enterprise software maker ServiceNow cut hundreds of jobs as it leans harder into automation, joining a wave of profitable tech firms reducing headcount to redirect spending toward AI.

HELP US

👋 Hi there! We are on a mission to provide as much value as possible for free. If you want this newsletter to remain free, please help us grow by referring your friends:

📌 Share your referral link on LinkedIn or directly with your friends.
📌 Check your referrals status here.

BONUS

Just for laughs 😏

YOUR FEEDBACK

What did you think of this week's email?

Your feedback helps us create better emails for you!

Login or Subscribe to participate in polls.

Until next time, take care! 🚀

Cheers,