[WEBINAR] The New Normal: Dealing with the Reality of an Unsecure World


Definition - What does Concatenation mean?

Concatenation, in the context of programming, is the operation of joining two strings together. The term"concatenation" literally means to merge two things together.

Also known as string concatenation.

Techopedia explains Concatenation

The process of merging data literals is one of the core applications of concatenation. The general syntax to achieve concatenation is given below:

(data type)(concatenation operator)(data type)=(concatenated expression)

Consider two strings: hello=”hello” and world=” world”

The concatenation syntax in different programming languages is given below.

hello & world : VB,VB.NET and Ada
strcat(hello, world) : C, C++ Perl, PHP
hello || world : REXX, SQL
hello || world : FORTRAN
hello ++ world : Erlang, Haskell
hello ^ world : Ocaml, Standard ML, F#
hello+world : Java

In addition to strings, concatenation can be applied to any other data type, including objects. For simple data types such as binary, integer, floating point, character and Boolean, prior to concatenation string type conversion is applied. Concatenation can then be easily applied using one of the above operators. For objects, concatenation implies the concatenation of data contained within the objects and is generally possible only if the structure of the objects is the same or if both objects belong to the same class. A method can be incorporated into the class to concatenate each and every data member of both objects and return the computed result to the main routine.

This definition was written in the context of Programming

Techopedia Deals

Connect with us

Techopedia on Linkedin
Techopedia on Linkedin
"Techopedia" on Twitter

Sign up for Techopedia's Free Newsletter!

Email Newsletter

Join thousands of others with our weekly newsletter

Free Whitepaper: The Path to Hybrid Cloud
Free Whitepaper: The Path to Hybrid Cloud:
The Path to Hybrid Cloud: Intelligent Bursting To Amazon Web Services & Microsoft Azure
Free E-Book: Public Cloud Guide
Free E-Book: Public Cloud Guide:
This white paper is for leaders of Operations, Engineering, or Infrastructure teams who are creating or executing an IT roadmap.
Free Tool: Virtual Health Monitor
Free Tool: Virtual Health Monitor:
Virtual Health Monitor is a free virtualization monitoring and reporting tool for VMware, Hyper-V, RHEV, and XenServer environments.
Free 30 Day Trial – Turbonomic
Free 30 Day Trial – Turbonomic:
Turbonomic delivers an autonomic platform where virtual and cloud environments self-manage in real-time to assure application performance.