Language: C++

#include <iostream>
#include <map>
#include <algorithm>
using namespace std;

int checkSimilarity(int a, int b, int c)
{
	if((a-b==0)|(b-c==0)|(a-c==0)
       {
         return 1;
       }
    return 0;
}
       
int findTriagnles(vector<int,int> v, int size)
{ 
  int count;
  for(int i=0; i<size; i++)
  {
    for(int j= i+1; j<size; j++)
    {
      for(int k=j+1; k<size; k++)
      {
        if(checkSimilarity(v.at(i), v.at(j), v.at(k)) 
           { continue;
           }
         if(v.at(i)+v.at(j) > v.at(k))
           {
             count++;
           }
      }
    }
  }
  return count;
}
           
int main()
{
	int size, element;
  	int count = 0;
  	vector<int,int> v;
  	cin >> size;
  	for(int i = 0; i<size; i++)
    {
      cin >> element;
      v.push_back(element);
    }
  	sort(v.begin(),v.end());
  	findTriangles(v, v.size());
}

Compiler output:
a.cc: In function 'int checkSimilarity(int, int, int)':
a.cc:8:38: error: expected ';' before '{' token
    8 |         if((a-b==0)|(b-c==0)|(a-c==0)
      |                                      ^
      |                                      ;
    9 |        {
      |        ~                              
a.cc:12:5: error: expected primary-expression before 'return'
   12 |     return 0;
      |     ^~~~~~
a.cc:11:9: error: expected ')' before 'return'
   11 |        }
      |         ^
      |         )
   12 |     return 0;
      |     ~~~~~~
a.cc:8:11: note: to match this '('
    8 |         if((a-b==0)|(b-c==0)|(a-c==0)
      |           ^
a.cc:13:1: warning: no return statement in function returning non-void [-Wreturn-type]
   13 | }
      | ^
a.cc: At global scope:
a.cc:15:19: error: 'vector' was not declared in this scope
   15 | int findTriagnles(vector<int,int> v, int size)
      |                   ^~~~~~
a.cc:4:1: note: 'std::vector' is defined in header '<vector>'; this is probably fixable by adding '#include <vector>'
    3 | #include <algorithm>
  +++ |+#include <vector>
    4 | using namespace std;
a.cc:15:26: error: expected primary-expression before 'int'
   15 | int findTriagnles(vector<int,int> v, int size)
      |                          ^~~
a.cc:15:30: error: expected primary-expression before 'int'
   15 | int findTriagnles(vector<int,int> v, int size)
      |                              ^~~
a.cc:15:38: error: expected primary-expression before 'int'
   15 | int findTriagnles(vector<int,int> v, int size)
      |                                      ^~~
a.cc:15:46: error: expression list treated as compound expression in initializer [-fpermissive]
   15 | int findTriagnles(vector<int,int> v, int size)
      |                                              ^
a.cc: In function 'int main()':
a.cc:41:9: error: 'vector' was not declared in this scope
   41 |         vector<int,int> v;
      |         ^~~~~~
a.cc:41:9: note: 'std::vector' is defined in header '<vector>'; this is probably fixable by adding '#include <vector>'
a.cc:41:16: error: expected primary-expression before 'int'
   41 |         vector<int,int> v;
      |                ^~~
a.cc:46:7: error: 'v' was not declared in this scope
   46 |       v.push_back(element);
      |       ^
a.cc:48:14: error: 'v' was not declared in this scope
   48 |         sort(v.begin(),v.end());
      |              ^
a.cc:49:9: error: 'findTriangles' was not declared in this scope; did you mean 'findTriagnles'?
   49 |         findTriangles(v, v.size());
      |         ^~~~~~~~~~~~~
      |         findTriagnles