Exercise: Sensitive Data Redactor
Explore how to create a Java method named smartRedact that filters sensitive content in chat messages. You will learn to process strings, compare words against a banned list, and mask characters selectively to maintain readability while protecting sensitive information.
We'll cover the following...
We'll cover the following...
Problem statement
You are working on a chat application that requires a content filter. Users sometimes send messages containing sensitive information (like passwords or banned terms). You need a method smartRedact that accepts a user’s message and a list of banned words. The method must replace some ...