Introduction
Here-strings let you write multiple lines of text easily without using many quotes or special characters.
@"
Your multiline text goes here
"@$text = @"
Hello,
This is a multiline string.
"@
Write-Output $text$json = @'
{
"name": "John",
"age": 30
}
'@
Write-Output $json$message = @"
Dear User,
Thank you for using our script.
Have a great day!
"@
Write-Output $message$name = "Alice" $text = @" Hello, $name! Welcome to PowerShell. "@ Write-Output $text
$text = @' Line 1 Line 2 "@ Write-Output $text
Pass the test and this pattern moves unknown