<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>Forem: Kunal2468</title>
    <description>The latest articles on Forem by Kunal2468 (@kunal2468).</description>
    <link>https://forem.com/kunal2468</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F954791%2Fddcd16ce-597e-4890-88ab-42c718919d8e.jpeg</url>
      <title>Forem: Kunal2468</title>
      <link>https://forem.com/kunal2468</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/kunal2468"/>
    <language>en</language>
    <item>
      <title>NewsCast: daily audio news podcasts for your interests (Cloudflare AI Challenge)</title>
      <dc:creator>Kunal2468</dc:creator>
      <pubDate>Sun, 14 Apr 2024 19:06:52 +0000</pubDate>
      <link>https://forem.com/kunal2468/newscast-daily-audio-news-podcasts-for-your-interests-cloudflare-ai-challenge-45p1</link>
      <guid>https://forem.com/kunal2468/newscast-daily-audio-news-podcasts-for-your-interests-cloudflare-ai-challenge-45p1</guid>
      <description>&lt;p&gt;&lt;em&gt;This is a submission for the &lt;a href="https://dev.to/devteam/join-us-for-the-cloudflare-ai-challenge-3000-in-prizes-5f99"&gt;Cloudflare AI Challenge&lt;/a&gt;.&lt;/em&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  What I Built
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;The app I built is designed to create &lt;strong&gt;personalized audio podcasts&lt;/strong&gt; based on the &lt;strong&gt;latest news and events&lt;/strong&gt; tailored to the user's &lt;strong&gt;specific interests&lt;/strong&gt;. &lt;br&gt;
By selecting their preferred topics, the app &lt;strong&gt;curates news articles&lt;/strong&gt; and other relevant content from various sources and &lt;strong&gt;converts them into an audio podcasts&lt;/strong&gt;. &lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Users can then listen to these &lt;strong&gt;custom podcasts&lt;/strong&gt; while multitasking, such as during their workout routine, traveling, or performing household chores. The goal is to provide a &lt;strong&gt;convenient and engaging way&lt;/strong&gt; for users to &lt;strong&gt;stay informed&lt;/strong&gt; about the topics they care about most.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Demo
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://newscast.pages.dev"&gt;NewsCast&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fpfoms3vlo80u6kcbb9z5.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fpfoms3vlo80u6kcbb9z5.png" alt="Landing page for newscast demo" width="800" height="441"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Listen to latest news now.&lt;br&gt;
&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fseviwqd4g2hwuero7jo1.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fseviwqd4g2hwuero7jo1.png" alt="listening newscast business news podcasts" width="800" height="440"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  My Code
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://github.com/kunal00000/NewsCast"&gt;Github - NewsCast&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Tech Stack :&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Next js&lt;/li&gt;
&lt;li&gt;Cloudflare Pages&lt;/li&gt;
&lt;li&gt;Workers AI API&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Journey
&lt;/h2&gt;

&lt;p&gt;The motivation behind this app stemmed from the realization that staying informed about the latest news and events can be a challenge in our fast-paced, multitasking world. With an abundance of information available, it's easy to feel overwhelmed or miss out on important updates, especially if they're not directly related to one's specific interests.&lt;/p&gt;

&lt;p&gt;This app tackles several problems:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Information Overload&lt;/strong&gt;: By curating and summarizing news articles based on user interests, the app helps users avoid information overload and focus on the topics that truly matter to them.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Accessibility&lt;/strong&gt;: Converting news content into an audio format allows users to consume information while multitasking, such as during their commute, workout, or household chores, making it easier to stay informed without sacrificing productivity.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Looking ahead, I envision expanding the app's capabilities to include interactive features, such as the ability to provide feedback or engage with the content through voice commands. Additionally, I plan to explore partnerships with major news organizations and content providers to further enhance the depth and breadth of the app's content offerings.&lt;/p&gt;

&lt;p&gt;I'm really feeling accomplished after building &lt;a href="https://newscast.pages.dev"&gt;NewsCast&lt;/a&gt; in this short span of time. I got to know about the Cloudflare AI challenge a bit late (i.e., 6th April), and I started to code on 9th April. Along with this, I was completely new to Cloudflare and serverless architecture. So, because of the challenge, I learned alot of new things and solved a problem that has been on my mind for a long time.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Multiple Models and/or Triple Task Types&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Models - &lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;code&gt;@cf/openai/whisper&lt;/code&gt; &lt;/li&gt;
&lt;li&gt;&lt;code&gt;@cf/facebook/bart-large-cnn&lt;/code&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Task Types -&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Summarization&lt;/strong&gt;: To provide &lt;strong&gt;concise and informative podcast content&lt;/strong&gt;, news articles are processed through a &lt;strong&gt;summarization model&lt;/strong&gt;.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Speech Recognition&lt;/strong&gt;: Once the podcast script is generated, a &lt;strong&gt;speech recognition model&lt;/strong&gt; is used to create &lt;strong&gt;accurate captions&lt;/strong&gt; for the audio version, enhancing accessibility and allowing users to easily follow along or reference specific sections.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Translation&lt;/strong&gt; [Pending to add]: To cater to a &lt;strong&gt;global audience&lt;/strong&gt;, the generated podcast scripts can be &lt;strong&gt;translated into various languages&lt;/strong&gt;, enabling users to consume the content in their preferred language.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Text Generation&lt;/strong&gt;: At the core of the app is a &lt;strong&gt;text generation model&lt;/strong&gt; that takes the summarized news articles and user interests as input, and generates a &lt;strong&gt;cohesive and engaging script&lt;/strong&gt; for the audio podcast.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

</description>
      <category>cloudflarechallenge</category>
      <category>devchallenge</category>
      <category>ai</category>
    </item>
    <item>
      <title>Ready to use Register Expressions</title>
      <dc:creator>Kunal2468</dc:creator>
      <pubDate>Tue, 13 Jun 2023 15:12:23 +0000</pubDate>
      <link>https://forem.com/kunal2468/ready-to-use-register-expressions-2590</link>
      <guid>https://forem.com/kunal2468/ready-to-use-register-expressions-2590</guid>
      <description>&lt;h2&gt;
  
  
  Regular-Expressions_regex
&lt;/h2&gt;

&lt;p&gt;The ReadyRegex repository is a comprehensive collection of ready-to-use regular expressions (regex) for various common tasks. This repository aims to provide a valuable resource for developers, data analysts, and anyone working with text data, by offering a wide range of regex patterns specifically designed for tasks such as email validation, phone number parsing, credit card number recognition, and more. &lt;/p&gt;

&lt;p&gt;Get latest regex at this &lt;a href="https://github.com/kunal00000/Regular-Expressions_regex"&gt;github repository&lt;/a&gt;.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Star repository if you feel it helped.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;To test regular expressions use &lt;a href="https://regex101.com/"&gt;regex101&lt;/a&gt;.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Whitespaces&lt;/li&gt;
&lt;li&gt;
Phone Number (various formats)

&lt;ol&gt;
&lt;li&gt;Validating phone numbers in various formats&lt;/li&gt;
&lt;li&gt;Normalizing phone numbers to a consistent format:&lt;/li&gt;
&lt;/ol&gt;


&lt;/li&gt;
&lt;li&gt;
Email Addresses

&lt;ol&gt;
&lt;li&gt;Validating email addresses:&lt;/li&gt;
&lt;li&gt;Extracting domain names from email addresses:&lt;/li&gt;
&lt;/ol&gt;


&lt;/li&gt;
&lt;li&gt;
URLs

&lt;ol&gt;
&lt;li&gt;Validating URLs:&lt;/li&gt;
&lt;li&gt;Extract Protocol&lt;/li&gt;
&lt;li&gt;Extract Domain&lt;/li&gt;
&lt;li&gt;Extract Path&lt;/li&gt;
&lt;li&gt;Extract Query Parameters&lt;/li&gt;
&lt;/ol&gt;


&lt;/li&gt;
&lt;li&gt;
Data Extraction

&lt;ol&gt;
&lt;li&gt;To extract dates:&lt;/li&gt;
&lt;li&gt;To extract time:&lt;/li&gt;
&lt;li&gt;To extract address:&lt;/li&gt;
&lt;li&gt;To extract values from XML:&lt;/li&gt;
&lt;/ol&gt;


&lt;/li&gt;
&lt;li&gt;
Credit Card

&lt;ol&gt;
&lt;li&gt;Validating credit card numbers:&lt;/li&gt;
&lt;li&gt;Extracting credit card expiration dates:&lt;/li&gt;
&lt;li&gt;
Matching CVV (Card Verification Value) codes: &lt;/li&gt;
&lt;/ol&gt;


&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;a id="whitespace"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Whitespace
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Regex:
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  \s+
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a id="phone-numbers"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Phone Numbers
&lt;/h3&gt;

&lt;p&gt;&lt;a id="validate-phone"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;Validating phone numbers in different formats-&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Regex pattern:
&lt;/li&gt;
&lt;/ul&gt;

&lt;pre class="highlight plaintext"&gt;&lt;code&gt;^(?:\+\d{1,3}\s?)?(?:\(\d{1,4}\)\s?)?(?:\d{1,4}[\s-])?\d{1,10}$
&lt;/code&gt;&lt;/pre&gt;



&lt;ul&gt;
&lt;li&gt;Example formats:&lt;/li&gt;
&lt;li&gt;+1 (123) 456-7890&lt;/li&gt;
&lt;li&gt;5551234567&lt;/li&gt;
&lt;li&gt;(999) 9999-9999&lt;/li&gt;
&lt;li&gt;+1 5551234567&lt;/li&gt;
&lt;li&gt;+1 (416) 555 7890&lt;/li&gt;
&lt;li&gt;+33 123456789&lt;/li&gt;
&lt;li&gt;+91 9876543210&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a id="normalise-phone"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;Normalizing phone numbers to a consistent format:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Regex pattern:
&lt;/li&gt;
&lt;/ul&gt;

&lt;pre class="highlight plaintext"&gt;&lt;code&gt;^(\+?\d{1,3}\s?)?(\(?\d{1,4}\)?\s?)?(\d{1,})[-\s]?(\d{1,})$
&lt;/code&gt;&lt;/pre&gt;



&lt;ul&gt;
&lt;li&gt;Example formats:&lt;/li&gt;
&lt;li&gt;+1 (123) 456-7890 (normalizes to +11234567890)&lt;/li&gt;
&lt;li&gt;555 123 4567 (normalizes to 5551234567)&lt;/li&gt;
&lt;li&gt;+55 (11) 98765-4321 (normalizes to 5511987654321)&lt;/li&gt;
&lt;li&gt;+86 10 1234 5678 (normalizes to +861012345678&lt;/li&gt;
&lt;li&gt;+91 98765 43210 (normalizes to +919876543210)&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a id="email-addresses"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Email Addresses
&lt;/h3&gt;

&lt;p&gt;&lt;a id="validate-email"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;Validating email addresses:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Regex pattern:
&lt;/li&gt;
&lt;/ul&gt;

&lt;pre class="highlight plaintext"&gt;&lt;code&gt;^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$
&lt;/code&gt;&lt;/pre&gt;



&lt;ul&gt;
&lt;li&gt;Example formats:&lt;/li&gt;
&lt;li&gt;&lt;a href="mailto:john.doe@example.com"&gt;john.doe@example.com&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;
&lt;a href="mailto:jane_smith123@gmail.com"&gt;jane_smith123@gmail.com&lt;/a&gt;
&lt;a id="extract-domain"&gt;&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;
&lt;li&gt;

&lt;p&gt;Extracting domain names from email addresses:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Regex pattern:
&lt;/li&gt;
&lt;/ul&gt;

&lt;pre class="highlight plaintext"&gt;&lt;code&gt;@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$
&lt;/code&gt;&lt;/pre&gt;



&lt;ul&gt;
&lt;li&gt;Example formats:&lt;/li&gt;
&lt;li&gt;
&lt;a href="mailto:john.doe@example.com"&gt;john.doe@example.com&lt;/a&gt; (extracts example.com)&lt;/li&gt;
&lt;li&gt;
&lt;a href="mailto:jane_smith123@gmail.com"&gt;jane_smith123@gmail.com&lt;/a&gt; (extracts gmail.com)&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a id="urls"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  URLs
&lt;/h3&gt;

&lt;p&gt;&lt;a id="validate-url"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;Validating URLs:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Regex pattern:
&lt;/li&gt;
&lt;/ul&gt;

&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  https?:\/\/[\w.-]+\.[\w.-]+[^\s]*
&lt;/code&gt;&lt;/pre&gt;



&lt;ul&gt;
&lt;li&gt;Example formats:

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://www.example.com"&gt;https://www.example.com&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://ftp.example.com/file.txt"&gt;http://ftp.example.com/file.txt&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a id="extract-comp"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;Extracting different components of a URL(&lt;a href="https://www.example.com/path/file.html?param1=value1&amp;amp;param2=value2):"&gt;https://www.example.com/path/file.html?param1=value1&amp;amp;param2=value2):&lt;/a&gt;&lt;br&gt;
&lt;a id="extract-protocol"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Extracting protocol:&lt;/li&gt;
&lt;li&gt;Regex pattern:
&lt;/li&gt;
&lt;/ul&gt;

&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  ^(https?):\/\/
&lt;/code&gt;&lt;/pre&gt;



&lt;ul&gt;
&lt;li&gt;Example format:

&lt;ul&gt;
&lt;li&gt;https://&lt;/li&gt;
&lt;li&gt;http://
&lt;a id="extract-domain"&gt;&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;
&lt;li&gt;Extracting domain:&lt;/li&gt;
&lt;li&gt;Regex pattern:
&lt;/li&gt;
&lt;/ul&gt;

&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  (https?):\/\/([a-zA-Z0-9.-]+)
&lt;/code&gt;&lt;/pre&gt;



&lt;ul&gt;
&lt;li&gt;Example format:

&lt;ul&gt;
&lt;li&gt;&lt;a href="http://www.example.com"&gt;www.example.com&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;
&lt;a href="http://www.google.com"&gt;www.google.com&lt;/a&gt;
&lt;a id="extract-path"&gt;&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;
&lt;li&gt;Extracting path:&lt;/li&gt;
&lt;li&gt;Regex pattern:
&lt;/li&gt;
&lt;/ul&gt;

&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  (https?):\/\/[a-zA-Z0-9.-]+(\/[^?\s]*)?
&lt;/code&gt;&lt;/pre&gt;



&lt;ul&gt;
&lt;li&gt;Example format:

&lt;ul&gt;
&lt;li&gt;/path/file.html
&lt;a id="extract-params"&gt;&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;
&lt;li&gt;Extracting query parameters:&lt;/li&gt;
&lt;li&gt;Regex pattern:
&lt;/li&gt;
&lt;/ul&gt;

&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  (https?):\/\/[a-zA-Z0-9.-]+(\/[^?\s]*)?(\?[^#\s]*)?$
&lt;/code&gt;&lt;/pre&gt;



&lt;ul&gt;
&lt;li&gt;Example format:

&lt;ul&gt;
&lt;li&gt;?param1=value1&amp;amp;param2=value2&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;
&lt;li&gt;Extracted Groups:

&lt;ul&gt;
&lt;li&gt;https&lt;/li&gt;
&lt;li&gt;/path/file.html&lt;/li&gt;
&lt;li&gt;?param1=value1&amp;amp;param2=value2&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a id="data-extraction"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Data Extraction
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;Extracting specific patterns from unstructured text:&lt;br&gt;
&lt;a id="extract-dates"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;To extract dates:
&lt;/li&gt;
&lt;/ul&gt;

&lt;pre class="highlight plaintext"&gt;&lt;code&gt;(\d{1,2})\/(\d{1,2})\/(\d{4})
&lt;/code&gt;&lt;/pre&gt;



&lt;ul&gt;
&lt;li&gt;Example:

&lt;ul&gt;
&lt;li&gt;Extract "12/31/2023" from a text.
&lt;a id="extract-times"&gt;&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;
&lt;li&gt;To extract times:
&lt;/li&gt;
&lt;/ul&gt;

&lt;pre class="highlight plaintext"&gt;&lt;code&gt;([01]\d|2[0-3]):([0-5]\d)
&lt;/code&gt;&lt;/pre&gt;



&lt;ul&gt;
&lt;li&gt;Example:

&lt;ul&gt;
&lt;li&gt;Extract "18:45" from a text.
&lt;a id="extract-address"&gt;&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;
&lt;li&gt;To extract addresses:
&lt;/li&gt;
&lt;/ul&gt;

&lt;pre class="highlight plaintext"&gt;&lt;code&gt;\d+\s[A-Za-z]+\s[A-Za-z]+,\s[A-Za-z]+\s\d+
&lt;/code&gt;&lt;/pre&gt;



&lt;ul&gt;
&lt;li&gt;Example:

&lt;ul&gt;
&lt;li&gt;Extract "123 Main St, New York 10001" from a text.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;

&lt;p&gt;Extracting values from structured data formats:&lt;br&gt;
&lt;a id="extract-xml"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;To extract values from XML:
&lt;/li&gt;
&lt;/ul&gt;

&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;lt;(.*?)&amp;gt;([^&amp;lt;]+)&amp;lt;\/\1&amp;gt;
&lt;/code&gt;&lt;/pre&gt;



&lt;ul&gt;
&lt;li&gt;Example:

&lt;ul&gt;
&lt;li&gt;Extract values between XML tags, such as
&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;
&lt;/ul&gt;

&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  # data
  &amp;lt;person&amp;gt;
    &amp;lt;name&amp;gt;John Doe&amp;lt;/name&amp;gt;
    &amp;lt;age&amp;gt;25&amp;lt;/age&amp;gt;
    &amp;lt;email&amp;gt;johndoe@example.com&amp;lt;/email&amp;gt;
  &amp;lt;/person&amp;gt;

  # Expected  Results 
  name John Doe
  age 25
  email johndoe@example.com
&lt;/code&gt;&lt;/pre&gt;




&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a id="credit-card"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Credit Card
&lt;/h3&gt;

&lt;p&gt;&lt;a id="validate-credit"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;Validating credit card numbers:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Regex Pattern:
&lt;/li&gt;
&lt;/ul&gt;

&lt;pre class="highlight plaintext"&gt;&lt;code&gt;^(?:\d{4}[ -]?){3}\d{4}$
&lt;/code&gt;&lt;/pre&gt;



&lt;ul&gt;
&lt;li&gt;Example Credit Card Numbers:

&lt;ul&gt;
&lt;li&gt;4111 1111 1111 1111&lt;/li&gt;
&lt;li&gt;5555-5555-5555-4444&lt;/li&gt;
&lt;li&gt;3782822463100058
&lt;a id="extract-expiry-date"&gt;&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;

&lt;p&gt;Extracting credit card expiration dates:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Regex Pattern:
&lt;/li&gt;
&lt;/ul&gt;

&lt;pre class="highlight plaintext"&gt;&lt;code&gt;(?:0[1-9]|1[0-2])\/20[2-9][0-9]
&lt;/code&gt;&lt;/pre&gt;



&lt;ul&gt;
&lt;li&gt;Example Expiration Dates:

&lt;ul&gt;
&lt;li&gt;12/2023&lt;/li&gt;
&lt;li&gt;05/2025&lt;/li&gt;
&lt;li&gt;09/2030
&lt;a id="extract-cvv"&gt;&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;

&lt;p&gt;Matching CVV (Card Verification Value) codes:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Regex Pattern:
&lt;/li&gt;
&lt;/ul&gt;

&lt;pre class="highlight plaintext"&gt;&lt;code&gt;^\d{3,4}$
&lt;/code&gt;&lt;/pre&gt;



&lt;ul&gt;
&lt;li&gt;Example CVV Codes:

&lt;ul&gt;
&lt;li&gt;123&lt;/li&gt;
&lt;li&gt;7890&lt;/li&gt;
&lt;li&gt;4321&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Connect with me - &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://github.com/kunal00000"&gt;Github&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://linkedin.com/in/kunalverma2468"&gt;Linkedin&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://twitter.com/KunalVerma2468"&gt;Twitter&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

</description>
    </item>
  </channel>
</rss>
