From 70b7bef0ce963eb23dd701f6bfcf5c7f7facb9e3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mateusz=20=C5=81oskot?= Date: Thu, 6 Aug 2020 13:11:37 +0200 Subject: [PATCH] Remove using namespace std; from header An obvious clean-up but also fix to avoid Windows API ambiguities (e.g. byte vs std::byte) --- Hungarian.cpp | 1 + Hungarian.h | 3 +-- testMain.cpp | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Hungarian.cpp b/Hungarian.cpp index deb4f71..bd48982 100644 --- a/Hungarian.cpp +++ b/Hungarian.cpp @@ -14,6 +14,7 @@ #include // for fabs() #include "Hungarian.h" +using namespace std; HungarianAlgorithm::HungarianAlgorithm(){} HungarianAlgorithm::~HungarianAlgorithm(){} diff --git a/Hungarian.h b/Hungarian.h index eeb7065..280dd6b 100644 --- a/Hungarian.h +++ b/Hungarian.h @@ -15,7 +15,6 @@ #include #include -using namespace std; class HungarianAlgorithm @@ -23,7 +22,7 @@ class HungarianAlgorithm public: HungarianAlgorithm(); ~HungarianAlgorithm(); - double Solve(vector >& DistMatrix, vector& Assignment); + double Solve(std::vector >& DistMatrix, std::vector& Assignment); private: void assignmentoptimal(int *assignment, double *cost, double *distMatrix, int nOfRows, int nOfColumns); diff --git a/testMain.cpp b/testMain.cpp index 139e134..98987c1 100644 --- a/testMain.cpp +++ b/testMain.cpp @@ -1,6 +1,6 @@ #include #include "Hungarian.h" - +using namespace std; int main(void) { pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy