0 like 0 dislike
128 views

Suppose we have the following two points in a 3D space:

The distance between point1 and point2 is:

Please create a ThreeD class to calculate the distance between two 3D points.

請宣告ThreeD類別來算出兩個3D點的距離。

Hint:

  • Write three public functions to Point class to get the value of X, Y, and Z
  • 建立三個public函數為讀取X,Y,Z的值

Example input:

1 1 1
2 3 4

Example output:

Distance is: 3.74166
[Normal] Coding (C++) - asked in Introduction to Computer Programming II (C++) by (9.9k points)
ID: 52068 - Available when: Unlimited - Due to: Unlimited
| 128 views
Welcome to Peer-Interaction Programming Learning System (PIPLS) LTLab, National DongHwa University
English 中文 Tiếng Việt
IP:172.70.179.114
©2016-2024

Related questions

0 like 0 dislike
0 answers
[Normal] Coding (C++) - asked May 17, 2018 in Introduction to Computer Programming II (C++)
ID: 52070 - Available when: 2018-04-26 17:48 - Due to: Unlimited
| 126 views
12,783 questions
183,443 answers
172,219 comments
4,824 users