If I have this code:
a = "hi" "pie" puts a
Will be printed hipie. Does Ruby automatically combine these features?
hipie
Yes. From Literals: String
Adjacent string literals are automatically concatenated by the interpreter:"con" "cat" "en" "at" "ion" #=> "concatenation" "This string contains " "no newlines." #=> "This string contains no newlines."
Adjacent string literals are automatically concatenated by the interpreter:
"con" "cat" "en" "at" "ion" #=> "concatenation" "This string contains " "no newlines." #=> "This string contains no newlines."
Source: https://habr.com/ru/post/1570390/More articles:Simple HTML email: CSS basic styles styles - pythonIt is not possible to use LWJGL correctly, the code gives errors - javaHow to update the original when cloning with the extension - javascriptHow to really compare java application memory usage - javaIon (angularjs) ion slider with ng repetition, not updated - angularjsWhat is the default wait value for Selenium WebDriver? - selenium-webdriverParsec-Haskell formatting parsing errors - haskellDoes LESS prevent duplication of styles? - lessUnhandled exception in vC ++ - HRESULT failed - c ++Debug / play EXC_BAD_ACCESS crash in CA :: release_objects - iosAll Articles