Skip to content
CodeWiki
Practice
Paths
Tracks
Cheatsheets
Playground
Glossary
AI era
Search
⌘K
English
English
Chinese
Practice
Paths
Tracks
Cheatsheets
Playground
Glossary
AI era
English
English
Chinese
Practice
/
Quiz
/
C#
/
Attributes
A project defines `[Cache(60)]` and applies it to a method, but no framework component re…
from Attributes
C# 14 / .NET 10
beginner
1 min
A project defines `[Cache(60)]` and applies it to a method, but no framework component reads `CacheAttribute`. What does the attribute do?
It stores metadata but does not cache calls by itself.
The CLR caches the return value for 60 seconds.
The compiler generates a dictionary around the method.
Reflection automatically intercepts each call.
Check
Ask AI about this kata
Report an error
previous kata
Which value can be used directly as a C# attribute argument?
Quiz
next kata
What does this program print?
Predict the output
A new version is available
Reload