Go: package main

import (
	"bufio"
	"os"
	"strconv"
	"fmt"
)

var scanner = bufio.NewScanner(os.Stdin)

func main() {
	result := make([]int, 6)
	scanner.Scan()
	n, _ := strconv.Atoi(scanner.Text())
	for i := 0; i < n; i++ {
		scanner.Scan()
		h, _ := strconv.ParseFloat(scanner.Text(), 64)
		if h < 165.0 {
			result[0]++
		} else if 165.0 <= h && h < 170.0 {
			result[1]++
		} else if 170.0 <= h && h < 175.0 {
			result[2]++
		} else if 175.0 <= h && h < 180.0 {
			result[3]++
		} else if 180.0 <= h && h < 185.0 {
			result[4]++
		} else if 185.0 <= h {
			result[5]++
		}
	}
	for i := 0; i < 6; i++ {
		fmt.Printf("%d:", i+1)
		for j := 0; j < result[i]; j++ {
			fmt.Print("*")
		}
		fmt.Println()
	}
}

C++: #include<iostream>
using namespace std;
int main(){
  int n,a1=0,a2=0,a3=0,a4=0,a5=0,a6=0;
  double high[100];
  cin >> n;
  for(int i=0;i<n;i++){
    cin >> high[i];
    if(high[i]<165.0){
      a1++;
    }
    else if(high[i]<170.0){
      a2++;
    }
    else if(high[i]<175.0){
      a3++;
    }
    else if(high[i]<180.0){
      a4++;
    }
    else if(high[i]<185.0){
      a5++;
    }
    else{
      a6++;
    }
  }
  cout << "1:";
  for(int i=0;i<a1;i++){
    cout << "*";
  }
  cout << endl;

  cout << "2:";
  for(int i=0;i<a2;i++){
    cout << "*";
  }
  cout << endl;

  cout << "3:";
  for(int i=0;i<a3;i++){
    cout << "*";
  }
  cout << endl;

  cout << "4:";
  for(int i=0;i<a4;i++){
    cout << "*";
  }
  cout << endl;

  cout << "5:";
  for(int i=0;i<a5;i++){
    cout << "*";
  }
  cout << endl;

  cout << "6:";
  for(int i=0;i<a6;i++){
    cout << "*";
  }
  cout << endl;
  return (0);
}

C++: #include <iostream>
using namespace std;
int a[6];
int main()
{
  int n,i,j;
  float h;
  cin >> n;
  while(n--){
    cin >> h;
    if(h < 165.0) a[0]++;
    else if(h < 170.0) a[1]++;
    else if(h < 175.0) a[2]++;
    else if(h < 180.0) a[3]++;
    else if(h < 185.0) a[4]++;
    else a[5]++;
  }
  for(i=0; i<6; i++){
    cout << (i+1) << ":";
    for(j=0; j<a[i]; j++){
      cout << "*";
    }
    cout << endl;
  }
  return 0;
}

C++: #include <bits/stdc++.h>

using namespace std;
#define rep(x,to) for(int (x)=0;(x)<(to);(x)++)
typedef int64_t ll;

int main()
{
	int n;
	cin >>n;
	int frq[6]={};
	const double lmt[] ={165, 170, 175, 180, 185, 99999};
	rep(i,n){
		double s;
		cin >>s;
		rep(j,6){
			if(s < lmt[j]){frq[j]++; break;}
		}
	}
	
	rep(i, 6){
		printf("%d:%s\n" ,i+1 ,string(frq[i], '*').c_str());
	}
}

C++: #include <iostream>
#include <fstream>
#include <string> 
#include <cmath>  
#include <cstdlib>
#include <ctime>
#include <vector>
#include <algorithm>
#include <numeric>
#include <map>
#include <set>
#include <stack>
#include <queue>
#include <deque>
#include <functional>
#include <cctype>
#include <list>
//#include <boost/multiprecision/cpp_int.hpp>

#define BIT(a) (1 << (a))
#define EPS (1e-10)

using namespace std;
//using namespace boost::multiprecision;

const long long MOD = 1000000007;
const int COUNTER_CLOCKWISE = 1;
const int CLOCKWISE = -1;
const int ONLINE_BACK = 2;
const int ONLINE_FRONT = -2;
const int ON_SEGMENT = 0;

class Point{
    public:
    double x, y;

    Point(double x = 0, double y = 0): x(x), y(y) {}
    
    Point operator+(Point p){return Point(x + p.x, y + p.y);}
    Point operator-(Point p){return Point(x - p.x, y - p.y);}
    Point operator*(double a){return Point(a * x, a * y);}
    Point operator/(double a){return Point(x / a, y / a);}

    bool operator < (const Point &p) const {
        return y != p.y ? y < p.y : x < p.x;
    }

    double norm(){return x * x + y * y;}
};
typedef Point Vector;
typedef vector<Vector> Polygon;

double cross(Vector a, Vector b){
    return a.x*b.y - a.y*b.x;
}

double dot(Vector a, Vector b){
    return a.x * b.x + a.y * b.y;
}

int ccw(Point p0, Point p1, Point p2){
    Vector a = p1 - p0;
    Vector b = p2 - p0;
    if (cross(a, b) > EPS)return COUNTER_CLOCKWISE;
    if (cross(a, b) > -EPS)return CLOCKWISE;
    if (dot(a, b) < -EPS)return ONLINE_BACK;
    if (a.norm() < b.norm())return ONLINE_FRONT;

    return ON_SEGMENT;
}

Polygon andrewScan(Polygon s){
    Polygon u, l;
    if (s.size() < 3) return s;
    sort(s.begin(), s.end());
    u.push_back(s[0]);
    u.push_back(s[1]);
    l.push_back(s[s.size()-1]);
    l.push_back(s[s.size()-2]);
    
    for (size_t i = 2; i < s.size(); i++){
        for (size_t n = u.size(); n >= 2 && ccw(u[n-2], u[n-1], s[i]) == COUNTER_CLOCKWISE; n--){
            u.pop_back();
        }
        u.push_back(s[i]);
    }

    for (int i = (int)s.size() - 3; i >= 0; i--){
        for (size_t n = l.size(); n >= 2 && ccw(l[n-2], l[n-1], s[i]) == COUNTER_CLOCKWISE; n--){
            l.pop_back();
        }
        l.push_back(s[i]);
    }

    reverse(l.begin(), l.end());
    for (size_t i = u.size() - 2; i >= 1; i--) l.push_back(u[i]);

    return l;
}

long long mod_pow(long long x, long long n){
    long long res = 1;
    for(int i = 0;i < 60; i++){
        if(n >> i & 1) res = res * x % MOD;
        x = x * x % MOD;
    }
    return res;
}


int bunpu[10];

int main(void){
    int N;
    cin >> N;
    double tmp[] = {0, 165, 170, 175, 180, 185};
    for (int i = 0; i < N; i++){
        double x;
        cin >> x;
        for (int j = 5; j >= 0; j--){
            if (tmp[j] <= x){
                bunpu[j]++;
                break;
            }
        }
    }
    for (int i = 0; i < 6; i++){
        cout << i+1 << ":";
        for (int j = 0; j < bunpu[i]; j++){
            cout << "*";
        }
        cout << endl;
    }


    return 0;
}

C++: #include <iostream>

using namespace std;

int main(int argc, char const* argv[])
{
	double input;
	int answer[6];
	int n;

	for( int i = 0;i < 6;i++ ) answer[i] = 0;

	cin >> n;

	for( int i = 0;i < n;i++ ){
		cin >> input;

		if( input < 165.0 ) answer[0]++;
		else if( input >= 165.0 && input < 170.0 ) answer[1]++;
		else if( input >= 170.0 && input < 175.0 ) answer[2]++;
		else if( input >= 175.0 && input < 180.0 ) answer[3]++;
		else if( input >= 180.0 && input < 185.0 ) answer[4]++;
		else if( input >= 185.0 ) answer[5]++;
	}

	for( int i = 0;i < 6;i++ ){
		cout << i + 1 << ":";
		for( int j = 0;j < answer[i];j++ ) cout << "*";
		cout << endl;
	}
	
	return 0;
}

C++: #include<stdio.h>
int main()
{
double N;
int num[41]={},A,B=0;

scanf("%d",&A);
for(int i=0;i<A;i++)
{
scanf("lf",&N);
B=N*10;
if((int)N<165)num[0]++;
else if((int)N>=1650&&(int)N<1700)num[1]++;
else if((int)N>=1700&&(int)N<1750)num[2]++;
else if((int)N>=1750&&(int)N<1800)num[3]++;
else if((int)N>=1800&&(int)N<1850)num[4]++;
else if((int)N>=1850)num[5]++;
else if((int)N>=1650&&(int)N<165)num[6]++;
}
for(int i=0;i<6;i++)
{printf("%d:");
for(int j=0;j<num[i];j++)
printf("*");
}
printf("\n");

return 0;
}

C++: #include<stdio.h>
int main()
{
double N;
int num[41]={},A,B=0;

scanf("%d",&A);
for(int i=0;i<A;i++)
{
scanf("%lf",&N);
B=N*10;
if((int)N<165)num[0]++;
else if((int)N>=1650&&(int)N<1700)num[1]++;
else if((int)N>=1700&&(int)N<1750)num[2]++;
else if((int)N>=1750&&(int)N<1800)num[3]++;
else if((int)N>=1800&&(int)N<1850)num[4]++;
else if((int)N>=1850)num[5]++;
else if((int)N>=1650&&(int)N<165)num[6]++;
}
for(int i=0;i<6;i++)
{printf("%d:");
for(int j=0;j<num[i];j++)
printf("*");
}
printf("\n");

return 0;
}