{"id":518,"date":"2023-06-14T19:37:43","date_gmt":"2023-06-14T18:37:43","guid":{"rendered":"https:\/\/ibex.tech\/blockchain\/?p=518"},"modified":"2023-06-14T19:43:37","modified_gmt":"2023-06-14T18:43:37","slug":"strings-general","status":"publish","type":"post","link":"https:\/\/ibex.tech\/blockchain\/cardano\/programming\/aiken\/strings\/strings-general","title":{"rendered":".Strings general"},"content":{"rendered":"\n<p><em>The use case for strings is extremely narrow in Aiken and on-chain code, they are only used for tracing, a bit like labels attached to specific execution paths of your program. Most of the time, you probably want to use a ByteArray instead and only resort to String for debugging.<\/em><\/p>\n\n\n\n<h4 class=\"wp-block-heading\">Creating strings<\/h4>\n\n\n\n<pre class=\"wp-block-code\"><code>@\"Hello world\"\n\n@\"Hello\nworld\"<\/code><\/pre>\n\n\n\n<h4 class=\"wp-block-heading\">Unicode<\/h4>\n\n\n\n<p>Under the hood text strings are UTF-8 encoded binaries and can contain any valid unicode.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>The use case for strings is extremely narrow in Aiken and on-chain code, they are only used for tracing, a bit like labels attached to specific execution paths of your program. Most of the time, you probably want to use a ByteArray instead and only resort to String for debugging. Creating strings Unicode Under the [&hellip;]<\/p>\n","protected":false},"author":5,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[39],"tags":[],"class_list":["post-518","post","type-post","status-publish","format-standard","hentry","category-strings"],"_links":{"self":[{"href":"https:\/\/ibex.tech\/blockchain\/wp-json\/wp\/v2\/posts\/518","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ibex.tech\/blockchain\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ibex.tech\/blockchain\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ibex.tech\/blockchain\/wp-json\/wp\/v2\/users\/5"}],"replies":[{"embeddable":true,"href":"https:\/\/ibex.tech\/blockchain\/wp-json\/wp\/v2\/comments?post=518"}],"version-history":[{"count":3,"href":"https:\/\/ibex.tech\/blockchain\/wp-json\/wp\/v2\/posts\/518\/revisions"}],"predecessor-version":[{"id":521,"href":"https:\/\/ibex.tech\/blockchain\/wp-json\/wp\/v2\/posts\/518\/revisions\/521"}],"wp:attachment":[{"href":"https:\/\/ibex.tech\/blockchain\/wp-json\/wp\/v2\/media?parent=518"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ibex.tech\/blockchain\/wp-json\/wp\/v2\/categories?post=518"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ibex.tech\/blockchain\/wp-json\/wp\/v2\/tags?post=518"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}