Challenge - 5 Problems
PowerShell Object Inspector
Get all challenges correct to earn this badge!
Test your skills under time pressure!
💻 Command Output
intermediate2:00remaining
What is the output type of Get-Member?
You run the command
Get-Process | Get-Member. What type of information does Get-Member display?PowerShell
Get-Process | Get-Member
Attempts:
2 left
💡 Hint
Think about what Get-Member does to objects piped into it.
✗ Incorrect
Get-Member shows the properties and methods available on the objects passed to it. It does not show actual data values like CPU or memory usage.
💻 Command Output
intermediate2:00remaining
What does this command output?
What is the output of this command?
'Hello World' | Get-MemberPowerShell
'Hello World' | Get-MemberAttempts:
2 left
💡 Hint
What type is a text string in PowerShell?
✗ Incorrect
The string 'Hello World' is a System.String object. Get-Member shows its properties and methods.
📝 Syntax
advanced2:00remaining
Which command correctly shows only properties of an object?
You want to see only the properties of a service object. Which command is correct?
Attempts:
2 left
💡 Hint
Check the exact parameter name for filtering member types.
✗ Incorrect
The correct parameter is -MemberType with value Property. Other options use wrong parameter names or values.
🔧 Debug
advanced2:00remaining
Why does this command fail?
You run this command:
But it returns an error. Why?
Get-Process | Get-Member -MemberType MethodsBut it returns an error. Why?
PowerShell
Get-Process | Get-Member -MemberType Methods
Attempts:
2 left
💡 Hint
Check the exact spelling of the parameter value.
✗ Incorrect
The parameter -MemberType expects singular values like 'Method', not plural 'Methods'. Using 'Methods' causes an error.
🚀 Application
expert3:00remaining
How to list only script methods of a custom object?
You have a custom object with script methods and properties. Which command lists only the script methods?
PowerShell
$obj = [PSCustomObject]@{Name='Test'; GetInfo={"Info"}}Attempts:
2 left
💡 Hint
Script methods are different from normal methods and properties.
✗ Incorrect
Script methods are members defined by script blocks. Use -MemberType ScriptMethod to list them.