0% found this document useful (0 votes)
26 views3 pages

47 Composed Function

A composed function is when the output of one function serves as the input for another, exemplified by f(g(x)). In the provided example, a number is doubled and then squared, resulting in a composed function that outputs 36 when the input is 3. Gowtham SB is a Data Engineering expert who shares knowledge through various platforms and has built a large community for aspiring data engineers.

Uploaded by

joanantoranjith
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
26 views3 pages

47 Composed Function

A composed function is when the output of one function serves as the input for another, exemplified by f(g(x)). In the provided example, a number is doubled and then squared, resulting in a composed function that outputs 36 when the input is 3. Gowtham SB is a Data Engineering expert who shares knowledge through various platforms and has built a large community for aspiring data engineers.

Uploaded by

joanantoranjith
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd

Gowtham SB

[Link]/in/sbgowtham/ Instagram - @dataengineeringtamil

✅ What is a Composed Function?


A composed function is when the output of one function becomes the input of
another — like f(g(x))

🔥 Super Simple Example


🎯 Task:
You want to take a number → double it → then square it.

🔹 Step 1: Define simple functions


def double(x):
return x * 2

def square(x):
return x ** 2

🔹 Step 2: Compose them manually


def composed(x):
return square(double(x)) # f(g(x)) → square of (x * 2)

🔹 Usage
print(composed(3)) # 36
# double(3) = 6 → square(6) = 36

🧠 Summary:
Gowtham SB
[Link]/in/sbgowtham/ Instagram - @dataengineeringtamil

Function Output

double(3) 6

square(6) 36

composed( square(double(3))
3) = 36

✅ TL;DR:

Composed function = f(g(x))


Apply g() first → pass result to f()

About the Author


Gowtham SB
[Link]/in/sbgowtham/ Instagram - @dataengineeringtamil

Gowtham SB is a Data Engineering expert, educator, and content creator with a


passion for big data technologies, as well as cloud and Gen AI . With years of
experience in the field, he has worked extensively with cloud platforms, distributed
systems, and data pipelines, helping professionals and aspiring engineers master the
art of data engineering.

Beyond his technical expertise, Gowtham is a renowned mentor and speaker, sharing
his insights through engaging content on YouTube and LinkedIn. He has built one of
the largest Tamil Data Engineering communities, guiding thousands of learners to
excel in their careers.

Through his deep industry knowledge and hands-on approach, Gowtham continues to
bridge the gap between learning and real-world implementation, empowering
individuals to build scalable, high-performance data solutions.

𝐒𝐨𝐜𝐢𝐚𝐥𝐬

𝐘𝐨𝐮𝐓𝐮𝐛𝐞 - [Link]

𝐈𝐧𝐬𝐭𝐚𝐠𝐫𝐚𝐦 - [Link]

𝐈𝐧𝐬𝐭𝐚𝐠𝐫𝐚𝐦 - [Link]

𝐂𝐨𝐧𝐧𝐞𝐜𝐭 𝐟𝐨𝐫 𝟏:𝟏 - [Link]

𝐋𝐢𝐧𝐤𝐞𝐝𝐈𝐧 - [Link]

𝐖𝐞𝐛𝐬𝐢𝐭𝐞 - [Link]

𝐆𝐢𝐭𝐇𝐮𝐛 - [Link]

𝐖𝐡𝐚𝐭𝐬 𝐀𝐩𝐩 - [Link]

𝐄𝐦𝐚𝐢𝐥 - [Link]@[Link]

𝐀𝐥𝐥 𝐌𝐲 𝐒𝐨𝐜𝐢𝐚𝐥𝐬 - [Link]

You might also like